Login support for mirrored domains?

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
Locked
guspasho
Registered User
Posts: 45
Joined: Thu Sep 15, 2005 9:25 pm
Location: Portland, OR
Contact:

Login support for mirrored domains?

Post by guspasho »

I have two domains. The trouble is no one can seem to agree which should be the "correct" one, kumoricon.org or kumoricon.com. Currently my phpbb board along with my whole site exists on .com. However, we have email aliases that use .org.

Clearly, the situation is a confusing mess but as the administrator of the message board I don't have much say over it.

The problem for phpbb is that the .org domain is mirroring the .com domain. When someone goes to kumoricon.org/forums/ and attempts to log in, phpbb attempts to send the logged-in user to kumoricon.com/forums/ . However, phpbb no longer recognizes their session, so it appears the user has been logged in and then immediately logged out. Once at kumoricon.com/forums, the user can log in again but finds their cookies have been reset (ie, all new posts have been marked as read that would otherwise have been marked as new if they logged in successfully the first time.) Some users get frustrated and don't even attempt to log in a second time, not knowing what has happened.

How can I allow users who access phpbb via kumoricon.org and kumoricon.com to both log in successfully? Keep in mind that the simpler answer of changing the mirror to a redirect is beyond my scope. Thanks.
Portland's Anime Convention, Labor Day weekend, http://www.kumoricon.com
guspasho
Registered User
Posts: 45
Joined: Thu Sep 15, 2005 9:25 pm
Location: Portland, OR
Contact:

Post by guspasho »

This is still an issue for me, so any help would be greatly appreciated. Thanks.
Portland's Anime Convention, Labor Day weekend, http://www.kumoricon.com
TopDawg
Registered User
Posts: 61
Joined: Tue Sep 12, 2006 1:38 am
Contact:

Post by TopDawg »

From what I'm understanding of this, it would be easiest to just redirect them.

Before you start worrying, it's not as difficult as you may think

All I would suggest is to add the following code into the <head> element of your site.

Code: Select all

<SCRIPT LANGUAGE="JavaScript">
<!-- begin hiding JavaScript from old browsers
// define redirect function
// to use this script, change redirect2.htm to required destination
		function redirect(){
			parent.location.href="http://www.domain.com"
		}
// End hiding JavaScript -->
</SCRIPT>
After you do that, all you have to do is make that page say "We are directing you to the correct page, if you are not directed to the correct page within 15 seconds, please click (here)" to let them know what's going on...
Locked

Return to “2.0.x Support Forum”