UBB.Dev
Posted By: RandyJG Start Page Status - 03/30/2004 7:23 AM
I noticed that when I have "Main Index" as the start page, what happens is when logging in you get displayed a blanked page that has a 1 second delay on it.

<html>
<head>
<meta http-equiv="Refresh" content="1;url={$config['phpurl']}/$main?Cat=$Cat">
</head>
<body>
</body>
</html>

Why not add an include file to this so that the screen doesn't go blank for that short second?

Or why isn't header("Location: {$config['phpurl']}/$main?Cat=$Cat"); exit; used instead?

I get the 1 second pause here, so I assume this is in verisons past 6.2 like this too?
Posted By: Rick Re: Start Page Status - 03/30/2004 6:01 PM
When you login, cookies have to be set properly before the next page is loaded, otherwise the next script won't actually know that you're logged in since cookies only get set when the headers are sent.

Including the file won't quite work because the same code is used when you go to your "My Home" setting after you've logged in, so programatically speaking this doesn't work.

Using header() works on some servers but not all of them. I used to do this, but roughly 50% of the time it doesn't set the cookie properly before the script being called by header() is loaded. So when that script is loaded it doesn't know your logged in.

In 6.5 I've dropped the meta refresh down to 0 so the redirect is more instantaneous.
Posted By: RandyJG Re: Start Page Status - 03/30/2004 6:48 PM
Ok, the cookies not setting properly all the time makes sense.

So in that case, just adding text to the blank page that says "Loading Forums..." or "Logging In..." instead of the blank while screen is my modification suggestion.
© UBB.Developers