WordPress.org

Support

Support » Requests and Feedback » WP 2.8.4 bug – WP_CONTENT_DIR does not propagate to get_stylesheet_uri()

WP 2.8.4 bug – WP_CONTENT_DIR does not propagate to get_stylesheet_uri()

  • Hi,

    I’ve just installed an instance of WP 2.8.4 whereby the software is in public_html/wordpress and in anticipation of multiple blogs, $table_prefix as well as WP_CONTENT_DIR have been set at install time.

    WP_CONTENT_DIR points to a peer directory public_html/oo_blog, where I’d copied the appropriate files. Everything seemed fine until I added a custom theme. At that point it became clear that WP_CONTENT_DIR value is not propagating to the get_stylesheet_uri() function (and similar others) used in the header. The following construct in the header

    <link rel=”stylesheet” href=”<?php bloginfo(‘stylesheet_url’); ?>” type=”text/css” media=”screen” />

    … attempts to load the new theme’s stylesheet from the default wordpress template location – not one specified in WP_CONTENT_DIR

    So far I’ve determined that function get_theme_root() does get the correct value – however it is not propagating to functions get_stylesheet_uri() and similar ones for pingback etc

Viewing 1 replies (of 1 total)
  • I’ve failed to follow instructions fully in http://codex.wordpress.org/Editing_wp-config.php section “Moving wp-content”

    Beside define( ‘WP_CONTENT_DIR’, $_SERVER[‘DOCUMENT_ROOT’] . ‘/blog/wp-content’ );
    … I was supposed to also define( ‘WP_CONTENT_URL’, ‘http://example/blog/wp-content’);

    SUGGESTION: it would be cleaner if the default DIR <-> URL relationship were established centrally by defining the web root dir of the site and the home page url in two constants. The paths down from there would by default be all identical, obviating the need to track separate DIR and URI vars for many resources. Just IMHO

Viewing 1 replies (of 1 total)
  • The topic ‘WP 2.8.4 bug – WP_CONTENT_DIR does not propagate to get_stylesheet_uri()’ is closed to new replies.