I have a wildcard SSL certificate for my doman - hdknowsit.com.au
I have a multisite and multinetwork wordpress installation at sites.hdknowsit.com.au
I have a mapped domain:
threecrosseschurch.com points to sites.hdknowsit.com.au/tcc
I have FORCE_SSL_LOGIN and FORCE_SSL_ADMIN set to true and I'm using a reverse proxy (Amazon AWS load balancer).
I've configured domain mapping to use the original address for login/admin.
I'm using the membership plugin to control access to certain pages, so users need to be able to login/logout.
I ran into a problem after login - clicking "Visit Site" pointed to https://threecrosseschurch.com, when it shouldn't be using SSL.
I corrected this by putting this code in mu-plugins:
return preg_replace('/^https:\/\//', 'http://', $url);
The only problem I'm left with is that logging out will log me out of https://sites.hdknowsit.com.au but not http://threecrosseschurch.com - after logout I'll click "Back to Three Crosses Church". The url points to http://sites.hdknowsit.com.au/tcc/, which is redirected by the plugin to threecrosseschurch.com, where the user remains logged in.
Is there any way to logout of both domains at once?