I have mulstisite

I have mulstisite subdomain installation.
When I enable Domain Mapping plugin all requests to subdomains end in infinite loop and can't be reached.
This started when I enbled SSL on my site and all subdomains ( wildcard SSL )

  • Nenad
    • Design Lord, Child of Thor

    Staff login is enabled.

    Apache directory config

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    # add a trailing slash to /wp-admin
    RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^(.*\.php)$ wp/$1 [L]
    RewriteRule . index.php [L]


    # Wordfence WAF
    <Files ".user.ini">
    <IfModule mod_authz_core.c>
    	Require all denied
    <IfModule !mod_authz_core.c>
    	Order deny,allow
    	Deny from all
    # END Wordfence WAF
    ## WP Defender - Prevent information disclosure ##
    Options -Indexes
    <FilesMatch "\.(txt|md|exe|sh|bak|inc|pot|po|mo|log|sql)$">
    Order allow,deny
    Deny from all
    <Files robots.txt>
    Allow from all
    ## WP Defender - End ##
  • Nenad
    • Design Lord, Child of Thor

    Any updates ?

    I've checked all settings - five times over - from Apache httpd, htaccess, wp-config, domain mapping settings...Budypress... everything...
    Since I got ssl certificate, I'm not able to turn on domain mapping. When Domain Mapping is active all subdomain go into infinite loop http->https.

    HELP !

  • Vaughan
    • Support/SLS MockingJay


    Is there any setting in your SSL config to force https in your servers CPanel. Try disabling that, this usually occurs when forcing https from the CPanel, and then something on the site tries to do it again.

    Could you grant support access again so I can take another look?


  • Nenad
    • Design Lord, Child of Thor

    So I'm not using CPanel - I set everything myself - Apache, php, mysql
    I'm forcing SSL on admin and login pages through wp-config
    Apache is not forcing SSL and php-fpm is not forcing SSL
    Also, since Google is "linking" secure pages more ( and geolocation will not be possible from unsecure pages ) it is important to have ssl on frontend also.
    On the other hand, if Chrome "remembers" that site has https, he will automatically switch to ssl for that domain - it is called 307 internal redirect - and this redirect is done in Chrome before any request is sent to the host.
    So when my page forced ssl on admin pages, Chrome will remeber this and force ssl even on http pages.

    And my scenario is this :
    when Domain mapping is disabled :
    - SSL works on main site architech.hr and on any subdomain subsite, both on frontend and backend

    when I enable Domain mapping :
    - main site works
    - all subdomains are unavailable because of the infinite loop
    - mapped domain doesn't work

    So, before I had ssl enabled, mapped domains worked, but there was also an infinite loop on subdomains.

    Remote access enabled.

  • Vaughan
    • Support/SLS MockingJay


    Can you try changing the home URL in the DB?

    I see your home URL for main site is still using http.

    Can you try adding the following to your main site current themes functions.php

    if(1 == current_blog_id()) {
        update_option('home', 'https://www.architech.hr');

    Then refresh your home page.

    Remove that code once you have finished.

    Then hopefully this might stop a few redirects.


  • Nenad
    • Design Lord, Child of Thor

    I've tried several combinations - last one including switching back to http
    but it didn't help
    I've updated all url's through database to https, but this one still remains ( home and site )

    I've re-enabled and mapped two domains - and they are working
    but - still subdomains are not working - to many redirects

    should subdomain sites havetheir home and site_url set to http or https ?

    I can access admin of subdomain sites but not frontend.
    All url are defined as https

  • Vaughan
    • Support/SLS MockingJay

    Hi Nenad,

    I've asked one of our SLS guys to help with this, I think this is related to a current bug where if pro-sites has been used, this redirect seems to happen. We may need your FTP login credentials to look deeper.

    Can you send your details using the following contact form:


    Alternatively, you can email directly to contact@wpmudev.org

    Mark for attn: Vaughan
    Include a ref URL to this thread.

    Please include the following details;
    - Site login details (super-admin if on multisite)
    - FTP login details so I can take a look at the theme/plugin files.
    - CPanel Credentials so I can look at the DNS settings & DB with Phpmyadmin


  • Lindeni Mahlalela
    • Recruit

    Hello Nenad,

    I hope you are doing great today. As I was going through some old threads in the forum I have noticed that this one is still open and was wondering if you still need help with this issue.

    I have noticed that you are using the latest version of Domain Mapping, how is this version working with reference to the redirect issue? Is it working as it should or you are still having the same issues with this new version? Even though we will be very happy to know that it is working perfectly, we are still more than happy to assist in any way possible if you are still having issues.

    Please let us know if you are still having issues with our domain mapping plugin and we will be happy to help.

    I hope you enjoy your day further.


  • Nenad
    • Design Lord, Child of Thor

    I have resolved this issue in this way :
    I've setup WPMU on Azure cloud, with VM's for web server and database separatly.
    On web server I'm running two instances of apache web server - one for http and one for https - and this is what fixed it ! Until that point there was no way for me to do this.
    I still have some questions regarding Domain Mapping and SSL for mapped domains. but I will open new ticket for this.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.