Obliterate
2005.05.04, 09:54 AM
Hi all, i spoke on iDev forums before about a new website i was developing (SLOWLY lol). Im stuck at a point in my development now though and am looking for help with php.
What i am looking to do is sort out a profile. You can enter a signature when you register and this gets stored in the MySql table fine, the problem is recalling it. I figured a session would be good to use in this situation and have just got trouble creating the session correctly.
$_SESSION['signature'] = ("SELECT sig FROM users WHERE username = '".$_POST['uname']."'");
That is the code i have used to create the session, now i am still learning php so i dont know why it doesnt work. When i write <? echo $_SESSION['signature']; ?> get the words "SELECT sig FROM users WHERE username = Users_username_here"
Please help, thanks
James
P.s if you wish to look at the site, goto www.thetrial.staronesw.com you then click register and make an account. At this point in time you dont need to enter a valid email if you dont want to. :D
Thanks again
What i am looking to do is sort out a profile. You can enter a signature when you register and this gets stored in the MySql table fine, the problem is recalling it. I figured a session would be good to use in this situation and have just got trouble creating the session correctly.
$_SESSION['signature'] = ("SELECT sig FROM users WHERE username = '".$_POST['uname']."'");
That is the code i have used to create the session, now i am still learning php so i dont know why it doesnt work. When i write <? echo $_SESSION['signature']; ?> get the words "SELECT sig FROM users WHERE username = Users_username_here"
Please help, thanks
James
P.s if you wish to look at the site, goto www.thetrial.staronesw.com you then click register and make an account. At this point in time you dont need to enter a valid email if you dont want to. :D
Thanks again