WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Multisite 3.4.1 wordpress

I redirected wp-admin with htaccess rules, and renamed wp-content and plugins with via wp-config http://codex.wordpress.org/Editing_wp-config.php#Moving_wp-content now I can no longer upload images.

when I try to upload an image it starts crunching but then either has an http error or says are you sure that you want to do this but then does not let me upload the image.

this is in .htacess

 RewriteEngine On
 RewriteBase /
 RewriteRule ^login$ wp-login.php
 RewriteRule ^index\.php$ - [L]

 # uploaded files
 RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

 # add a trailing slash to /wp-admin
 RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

 RewriteRule ^([_0-9a-zA-Z-]+/)?private-admin/?$ $1private-admin/index.php?wdeb_on [R=301,L]
 RewriteRule ^private-admin(.*)$ wp-admin$1

 RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin/([_0-9a-zA-Z-]+).php\?(.*)$ $1private-admin/$2\.php\?$3 [R=301,L]

 RewriteCond %{REQUEST_FILENAME} -f [OR]
 RewriteCond %{REQUEST_FILENAME} -d
 RewriteRule ^ - [L]
 RewriteRule  ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
 RewriteRule  ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
 RewriteRule . index.php [L]

This is in wp-config /* Changes to redirect wp-admin to private-admin folder */

 if(preg_match('/wp-admin/i', $redirect_url)) header('Location:    '.str_replace('wp-admin', 'private-admin', $redirect_url));

/** Change name of wp-config and plugins */
 define( 'WP_CONTENT_DIR', $_SERVER['DOCUMENT_ROOT'] . '/private-content' );
 define( 'WP_CONTENT_URL', 'http://mysite.com/private-content');
 define( 'WP_PLUGIN_DIR', $_SERVER['DOCUMENT_ROOT'] . '/private-content/resources' );
 define( 'WP_PLUGIN_URL', 'http://mysite.com/private-content/resources');
 define( 'PLUGINDIR', $_SERVER['DOCUMENT_ROOT'] . '/private-content/resources' );

This is the image url path in network> settings>Sites>/>image upload path: private-content/uploads

Suggestions on how I can fix this? Thanks.

share|improve this question
I redirected wp-admin with htaccess rules – what does this mean? Please add the code you use for this. – toscho Aug 7 '12 at 9:57
boldI redirected wp-admin with htaccess rules – what does this mean? Please add the code you use for this.**bold** @toscho I added the wp-admin and htaccess rules to the original post. Any suggestions on how to fix? – SamDom Aug 9 '12 at 19:48
up vote 0 down vote accepted

The issue was that half of the site still used the old wp-content for images under this method so I ended up changing the wp-admin doing a find and replace instead of a htacess redirect.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.