[resolved] Forced trailing slash and "www" (2 posts)

  1. mairaj
    Posted 4 years ago #


    just activated my WordPress network. I chose sub directories to create the sites at. Everything worked fine except to the following two problems.

    1. The first sub-site that I have created is showing a trailing slash, if I try to go to the address with slash it redirects to the slashed version.

    I have this -> http://www.mymainsite.com/mysubsite/
    I wish this -> http://www.mymainsite.com/mysubsite

    2. I can only access my sub-site with a "www" without it the it redirects to the main-site!

    It works fine if I type http://www.mymainsite.com/mysubsite

    It redirects if I type mymainsite.com/mysubsite -> redirects to -> http://www.mymainsite.com

    NOTE: I'm not using any domain mapping plugin at the moment.

  2. You can't. You must have the trailing slash. It's part of WP.

    As for the www/non-www thing, there are a couple possibilities. One is that when you set up WP, you weren't consistant.

    In your database, open the wp_blogs table.
    blog_id 1, should be your main site. The value under domain should match your chosen site url. For example, the value in your wp_config.php file:

    define( 'DOMAIN_CURRENT_SITE', 'www.example.com' );

    They must match.

    If they do, we'll have to do a .htaccess redirect to sort that out.

Topic Closed

This topic has been closed to new replies.

About this Topic