How to make URL loads only on login


Posted on 16th Feb 2014 07:03 pm by admin

On my page, when a user login he's redirects to user_home.php. I made it also to open the chat screen when the user login.
This is the code:
Code: // USER IS LOGGED IN, FORWARD TO USER HOME
if( $user->user_exists )
{
header("Location: user_home.php");
header("javascript:launchChat();");
exit();
}
The problem is that every time, the user open user_home.php, the chat screen reloads (the user is loged out and loged in to the chat).
How to make the chat screen loads ONLY THE FIRST time, when the user login?

No comments posted yet

Your Answer:

Login to answer
327 Like 17 Dislike
Previous forums Next forums
Other forums

Load Animated Image while cache is serve
I have a page that loads up using cache and took about 1 to 2 minutes before it loads to the page. <

Time script, set to my time zone?
I am using this line to get the date and time

Code: $time = date(F." ".d.", &q

Adding Different Numbers From MySQL
Basically I have a mysql database with a couple prices as the following:

9.99
9.99
9.99

Need help in Generating Combinations
Need help generating all possible combination of names in an array

Lets say i have the follow

Stopped working!
So I had to change some stuff, none of it major. Stuff like the extension_dir and such. BEFORE I did

Coding Critique
I was hoping someone could take a second and look down my code and see if they see any problems with

Help Ordering Arrays
Hi, I have 3 arrays as shown below.

Code: $users = $this->get_latest_users();
$flir

Select question
Hi,

First I would like to say that php is pretty new for me..
so please don't shoot me if

Why will this program not run if the variables are not global?
Hey guys I have a kind of perplexing situation that is probably simple, but I can't seem to understa

Navigation include for all site directories
Hi,

I need a navigation include that can deal with directories at different levels on a site.

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash