I'm new to php and still learning and reading. I need some help and suggestions about something I want to do. I don't necessarily need code, just wondering on how to go about doing this.
I want to connect to a database and select certain fields and then return that data sorted in descending order. I would like to just return every single record and have it sort in descending order by what the value of a particular field is. Eventually I would just like to have it report just the 10 highest records after they are sorted.
Does this sound possible and can I have it fetch and return the data just by clicking a link to the php file, or will I have to setup a form and a submit button? I really don't want to compare the data to anything, I just want to pull everything out of the database and list certain fields sorted according to the value of a certain field.
Do I create a loop to have it keep printing the values for each record (there are about 1300). Also, if someone could explain the sort function to me that would be helpful. The field I am going to be sorting in descending order has a numerical value too.
ANy help is appreciated. Just want to learn more.