Jump to content

Show Voting System Results


GRooVeZ

Recommended Posts

hi guys

 

i am building a voting system for my gaming website

 

people sign up for matches, and those will be played at 3-5 different maps

people can vote for wich maps they want to play

 

each player can choose 3 maps, also 3 x the same map

 

now the results of that voting system are shown on the page like this

 

There is 1 vote for Map 1

There are 5 votes for Map 2

There is 1 vote for Map 3

There are 2 votes for Map 7

There is 1 vote for Map 4

There is 1 vote for Map 5

There are 8 votes for Map 8

 

now i want to make a script that picks the maps that will be played, so only show the 3-5 best results

 

in the example above it woud be 2 x map 8 and 1x map 2

but im not sure how to start on this

 

the db table of the votes is built like this

 

id matchid playerid mapid mapname

1 113 195 1 NukeTown

2 113 195 2 Grid

3 113 195 1 NukeTown

4 114 195 1 NukeTown

5 114 195 1 NukeTown

 

any advice or thoughts on this?

 

thanks

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.