show uploaded content from users
I'm very new to php, so please be gentle
I have users who log in, and now I want to show all of the users on a particular page. Each user shown would then be clicked on and up would pop all of their content that they have uploaded to a table in my database.
The table in question is named 'Story', and the two fields I want echoed are 'title' and 'story'.
Any help would be much appreciated. Hope my explanation makes sense.
Are you just asking how to display the uploads data from the table? There is a class which will allow you to do this in a couple lines of code, and generate the table for you HERE.
If you look in the documentation at example 10, this will demonstrate how to select from a database and return the results in a table....don't be thrown off by all the optional statements, they are just demonstrating advanced features.
The only thing you really need to know is the query:
"SELECT title,story FROM Story WHERE userID=''" (This is just a demo, i'm assuming there is a field in the table for the users id)
Last edited by hastx; 10-17-2012 at 10:01 AM.
We do precision guesswork
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)