Ok, so first off, I know next to nothing about PHP. Im figuring it out bit by bit, but Im still a total noob.
What I need to do is basically this:
[ul][li]I will have a number of items that need to be listed on a webpage[/li]
[li]Each item will have a score, based on how many votes its recieved.[/li]
[li]I need to have the list of items sorted by score.[/li][/ul]
I already know how Ill retrieve the data for the score, and how to use forms to submit a vote and such. What I need to figure out is
A) How to sort the items in a list by their score
B) how to add each vote to the total
For the adding, I imaging it would be something like thios psuedo code:
var Current_score = (score retrieved from database)
if vote recieved
current_score = current_score +1
(send new score back to database)
Can anyone help me out with this?