WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

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

By defining TEMPLATEPATH, STYLESHEETPATH, WP_CONTENT_DIR and WP_CONTENT_URL merely affect the naming changes to wp-content.

Is there any way to redefine the theme path and plugin path, so the new path can propagate through function calls such as get_options or bloginfo?

share|improve this question
up vote 3 down vote accepted

For themes you can use register_theme_directory() function to add additional directories for WP to be aware of. I don't think I ever seen this used in practice, so not sure if there are any complications possible.

For plugins you can define WP_PLUGIN_DIR and WP_PLUGIN_URL constants in wp-config.php.

share|improve this answer
register_theme_directory() it is. Thank you. – Sean Lee Aug 14 '11 at 20:18

You can change the wp-content folder which changes the plugin and theme dir. To do this you put change the folder location and put these two lines in your wp-config.php file:

define ('WP_CONTENT_DIR','/full/path/to/your/content/dir');
define ('WP_CONTENT_URL','http://example.com/full/path/to/your/content/dirs/url');

Just be aware that some plugins and themes are badly coded and may break because they are hard coded to look at the wp-content dir.

share|improve this answer
Thanks for trying, but my question was on how to continue using get_bloginfo and get_option after switching theme directory. – Sean Lee Aug 14 '11 at 20:20

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.