securing user page links

Thread Solved
Reply

Join Date: Oct 2007
Posts: 32
Reputation: rohitrohitrohit is an unknown quantity at this point 
Solved Threads: 2
rohitrohitrohit's Avatar
rohitrohitrohit rohitrohitrohit is offline Offline
Light Poster

securing user page links

 
0
  #1
Jan 17th, 2009
hi all

new to php .....
how to protecte links on userpage when he login successfully.
i want that out side user who not logged in ,can not see page after copy those links in browser.any example.

thanx in advan......
Reply With Quote Quick reply to this message  
Join Date: Nov 2007
Posts: 596
Reputation: buddylee17 has a spectacular aura about buddylee17 has a spectacular aura about 
Solved Threads: 125
buddylee17's Avatar
buddylee17 buddylee17 is offline Offline
Posting Pro

Re: securing user page links

 
0
  #2
Jan 17th, 2009
Look into using sessions for authentication. Basically the idea is:
  1. <?php
  2. session_start();
  3. if($_SESSION['loggedIn']==true){
  4. echo "This content will only be viewable for users who are logged in";
  5. }
  6. else{
  7. echo "You are not logged in";
  8. }?>
Lost time is never found again.
- Benjamin Franklin
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Other Threads in the PHP Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC