Jump to content


Photo

SESSION help!!!!


  • Please log in to reply
2 replies to this topic

#1 techiefreak05

techiefreak05
  • Members
  • PipPipPip
  • Advanced Member
  • 494 posts
  • LocationER, MN

Posted 01 August 2006 - 11:38 AM

Hi, I hold the usernames of my site in SESSIONS, this is what I use: $_SESSION['username'], now how do i do something like this :

if $_SESSION['username'] = "example"{
echo "MESSAGE THAT ONLY 1 USER WILL SEE"}

So basically,if the session equals something, echo something.. but IDK the right PHP syntax...
Link shortener with advanced, detailed statistics:

http://tyny.us/

#2 Ifa

Ifa
  • Members
  • PipPipPip
  • Advanced Member
  • 88 posts
  • LocationRauma, Finland

Posted 01 August 2006 - 11:40 AM

if($_SESSION['username'] == "example"){ echo "MESSAGE THAT ONLY 1 USER WILL SEE"; }
I'm just a guy who likes to code for fun...

#3 techiefreak05

techiefreak05
  • Members
  • PipPipPip
  • Advanced Member
  • 494 posts
  • LocationER, MN

Posted 01 August 2006 - 11:43 AM

Thanks alot!! :D
Link shortener with advanced, detailed statistics:

http://tyny.us/




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users