Jump to content

how users can login to the system and see the contents added by himself/herself

- - - - -

  • Please log in to reply
1 reply to this topic

#1
jadago

jadago

    Newbie

  • Members
  • Pip
  • 5 posts
hi! everyone,currently im doing a directory system and my problem is that i want the user to login to the system and add some contents and when he/she login again he suppose to see only his contents he added and not contents of others.
Can you help me to solve this problem?

#2
Alexander

Alexander

    It's Science!

  • Moderators
  • 4,118 posts
  • Location:Vancouver, Eh! Cleverness: 200
You can supply an 'owner' column along with each of your row entries, and only display the entry if the owner column matches them:
SELECT column(s) FROM table WHERE owner = '$current_user_id'

Be sure to read the updated FAQ! || Health is achieved through the same 10,000 steps.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users