WordPress.org

Ready to get started?Download WordPress

Forums

WordPress MU Domain Mapping
The domain mapping plugin only works if the site is installed in / (5 posts)

  1. evelioml
    Member
    Posted 1 year ago #

    With DNS and Apache well configure WP 3.5.2 give me this warning.

    The domain mapping plugin only works if the site is installed in /.
    This is a limitation of how virtual servers work and is very difficult to work around.

    Had to downgrade to 3.4.2 and then everything goes as expected.

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

  2. Ron Rennick
    MultiSite Guru
    Plugin Author

    Posted 1 year ago #

    Just for clarification for anyone reading the thread - Domain mapping will work in 3.5.X as long as WP is installed in the root.

    The issue above wasn't the WP version. It was that WP 3.5.X allows you to install WP in its own folder (which isn't supported by DM yet).

  3. SRD75
    Member
    Posted 1 year ago #

    Hi Ron.

    Do you have an ETA for when DM will support non root installs of WP?

    Thank you,
    Steve.

  4. Ron Rennick
    MultiSite Guru
    Plugin Author

    Posted 1 year ago #

    I created a new install in a folder for another research project so I'm half way there. If I get some time to look at it this weekend I may have something by the first of the week,

  5. alfreddatakillen
    Member
    Posted 1 year ago #

    Hi!

    I have wordpress in its own directory, as described here: http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    So, my sites are at the domain root, but wordpress is installed in /wordpress.
    In this situation, this plugin creates a redirect loop for the main blog (blog #0), since the URL from get_option() will be http://example.org/wordpress but the if-statement in redirect_to_mapped_domain() expects only http://example.org

    So, what I did was making sure get_original_url() always returns the protocol + domain name ONLY, by adding this piece of code in get_original_url() directly after $orig_url is set from get_option/get_blog_option:

    $orig_url_arr = explode('/', $orig_url);
    if (count($orig_url_arr) > 3) {
        $orig_url = $orig_url_arr[0] . '//' . $orig_url_arr[2];
    }

    This is not the most beautiful solution (since the compared URLs will actually not be the correct ones), but it seems to work fine so far.

    I'm not sure if this solution will also work if you want your wordpress root to be accessed from http://example.org/blog, but I thought this was a related problem/solution, so att decided to share this here. :)

    Thanks for a nice plugin! :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic