Jump to content


This topic is now archived and is closed to further replies.


Login Display

Recommended Posts

I'm looking for a way to once someone logs in using there username and pw, it will display info that I have stored about that person. Something like you see on Amazon or other big sites, ya know.
A) How do I display the stuff on a html page
B) Where do I store the stuff
I'm still new at php, so if theres a script out there for me or something..

Share this post

Link to post
Share on other sites
ok what you are referring to is sessions or cookies.

for sessions do this in your login script.

at the begining of your script put this. This must come first, before anything else.


Now after you process the login. You can set the session variables like this
[code=php:0]$_SESSION['username'] = $username[/code] You can repeat this for anything that you want to store in the session

Now you can display this is html like this

<head><title>Test Page</title></head>

<p>Welcome <b><?php echo $_SESSION['username']; ?></b>. You are now logged in.</p>
<!---some more html--->

Hope this helps,

Share this post

Link to post
Share on other sites


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.