The MU forums have moved to WordPress.org

Themes working a sub directory blogs. (2 posts)

  1. darkishdave01
    Member
    Posted 13 years ago #

    Hello,

    I am have problems with getting themes working a sub directory blogs. I am only getting text on text.

    I have a feeling it is to do with .htaccess.

    When I look at the source code for the index of the sub blog I see the link to the style sheet as "http://example.com/test1/wp-content/themes/default/style.css". But in fact the style sheet is located at "http://example.com/wp-content/themes/default/style.css"

    Here is my .htaccess file:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    Options +FollowSymLinks
    RewriteCond %{HTTP_HOST} ^www\.(.*)
    RewriteRule (.*) http://%1/$1 [R=301,L]
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    
    # END WordPress

    By the way I edited the .htaccess to redirect http://www.example.com to http://example.com. It is important that this is keep as www leads to a 404.

    Thanks.

  2. andrea_r
    Moderator
    Posted 13 years ago #

    The stylesheet links are correct; you've got the wrong htaccess file. That's for single WP, not MU or multisite.

    MU already strips out the www.

    RewriteEngine On
    RewriteBase /
    
    #uploaded files
    RewriteRule ^(.*/)?files/$ index.php [L]
    RewriteCond %{REQUEST_URI} !.*wp-content/plugins.*
    RewriteRule ^(.*/)?files/(.*) wp-content/blogs.php?file=$2 [L]
    
    # add a trailing slash to /wp-admin
    RewriteCond %{REQUEST_URI} ^.*/wp-admin$
    RewriteRule ^(.+)$ $1/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule . - [L]
    RewriteRule  ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L]
    RewriteRule  ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]
    
    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    </IfModule>

About this Topic

  • Started 13 years ago by darkishdave01
  • Latest reply from andrea_r