chronister Posted May 13, 2007 Share Posted May 13, 2007 I assume that when a person logs in you use a session variable. When you set the session variable for the login, just grab the user id as well and set that as a session variable. When a person uploads an image, just add another piece into your code to insert that session variable containing their user id in the image table. That way when you go to pull the image out of the database, you can do something like $user_id=$_SESSION['user_id']; "SELECT * FROM images WHERE user_id='$user_id'"; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.