Voting Poll - Allow One vote only

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
buddok
Forum Commoner
Posts: 50
Joined: Tue May 25, 2004 2:44 pm

Voting Poll - Allow One vote only

Post by buddok »

hey ppl Ive made my poll and it works fine an all but i wanted to no if anyone could help me, i want ti so the user can only vote once anyone no how to do this in a very simepl way if possiable ? thanks ...
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

votes table:

poll_id
user_id

if their user_id is in the table under that poll, they voted :D
User avatar
buddok
Forum Commoner
Posts: 50
Joined: Tue May 25, 2004 2:44 pm

Post by buddok »

ok i didnt get how to do that though ? :S ?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

all votes get stored in that table.. you could store the poll choice data too in there, if you want to be able to track that data.
Post Reply