Re: [PHP] Where to insert a phrase in the right place

2007-04-10 Thread Richard Lynch
On Mon, April 9, 2007 2:51 pm, Mário Gamito wrote: > I'm making this site that was static and now has some dynamic > features, > so it's a little bit patched :) > > If you care to visit > http://www.telbit.pt/2/login.php > > you'll notice that the word "Welcome" is already present, and only > shoul

Re: [PHP] Where to insert a phrase in the right place

2007-04-10 Thread Jan Brucek
Hi, it seems that you set the $_SESSION['greeted'] variable and do not unset it anywhere. If user wants to log-in, and his credentials are OK, you then create session and set this varaible you want. If it isn't OK, you need to unset the variable or/and destroy the session so that the variable won

Re: [PHP] Where to insert a phrase in the right place

2007-04-09 Thread Mário Gamito
Hi, André Medeiros wrote: > session_start(); > if(!isset($_SESSION['greeted'])) { >echo "Welcome"; >$_SESSION['greeted'] = 1; > } > ?> It doesn't work :( if ($_SESSION['greeted'] == 1) print('Welcome ' . $name); $_SESSION['greeted'] is always equal to 1 as set in the beginning of the

Re: [PHP] Where to insert a phrase in the right place

2007-04-09 Thread Mário Gamito
Hi, Jay Blanchard wrote: > [snip] > How can i make the word "Welcome" appear only after the login ? > [/snip] > > If you set a cookie upon login you can then check for the existence of the > cookie. If the cookie exists do not display 'Welcome'. I have: session_start(); session_register("email"

RE: [PHP] Where to insert a phrase in the right place

2007-04-09 Thread Jay Blanchard
[snip] How can i make the word "Welcome" appear only after the login ? [/snip] If you set a cookie upon login you can then check for the existence of the cookie. If the cookie exists do not display 'Welcome'. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php

[PHP] Where to insert a phrase in the right place

2007-04-09 Thread Mário Gamito
Hi, I'm making this site that was static and now has some dynamic features, so it's a little bit patched :) If you care to visit http://www.telbit.pt/2/login.php you'll notice that the word "Welcome" is already present, and only should be after the download. Also, the error "You didn't fill all