WordPress.org

Ready to get started?Download WordPress

Forums

WordPress MU Domain Mapping
Mapped Domains Not Working Correctly (3 posts)

  1. Tim Moore
    Moderator
    Posted 3 years ago #

    I've got domain mapping set up, but have one issue. I have WordPress installed in a subdirectory style and am mapping domains to subdomains.

    For example:

    Real URL is "http://example.com/mysite"
    Domain Mapped URL is "http://mysite.example.com"

    The issue is, when a visitor types in the Real URL, it goes to "http://mysite.example.com/mysite" rather than to just the Domain Mapped URL.

    Any idea how to resolve this?

    Thanks,

    Tim

    http://wordpress.org/extend/plugins/wordpress-mu-domain-mapping/

  2. Tim Moore
    Moderator
    Posted 3 years ago #

    Well, I've got this down to the fact that the Real URL needs to have a trailing slash in order to work correctly. Now looking for a solution to add the trailing slash on requests lacking it.

  3. Tim Moore
    Moderator
    Posted 3 years ago #

    It looks like this addition to the .htaccess file in the WordPress root directory solves the issue:

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_URI} !\..+$
    RewriteCond %{REQUEST_URI} !/$
    RewriteRule ^(.+)$ $1/ [R=301,L]

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic