I'm uploading files via php script straight to a folder called 'uploads' on my mysql server.
I can list all the files uploaded.
My problem is listing only selected files from this folder for each user that login.
i.e. user A logs in with username 'theboss'
The user will be directed to a page where only the files in the folder 'uploads' starting with 'theboss_****' will be retrieved and listed.
The user should then be able to select the file/s he wants to download to his PC.
Any help will be greatly appreciated.
4x4
4x4biker
0
Newbie Poster
Recommended Answers
Jump to PostWhen the user logs in, add his username to the session and append the username to the upload directory and list the files.
Jump to Postsince the user should be logged in to upload files, why don't you just put the uploaded file name into the database with their user id. then all you have to do to get the files for a certain user by one simple query:
SELECT * FROM `files` WHERE `id` …
All 7 Replies
nav33n
472
Purple hazed!
Team Colleague
Featured Poster
4x4biker
0
Newbie Poster
4x4biker
0
Newbie Poster
somedude3488
228
Nearly a Posting Virtuoso
4x4biker
0
Newbie Poster
nav33n
472
Purple hazed!
Team Colleague
Featured Poster
4x4biker
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.