Jump to content

Recommended Posts

Hi There,

 

I am just about to start work on a large community based website, whereby a lot of the content is created based on membership voting / rating other members articles / photos / pictures etc....

 

This will probably have a large user base, so I was wondering what the best way to allow only unique votes per user?

 

If I had a table for votes.... with the user ID and articleID for example, this would be fine for a low count, but if there are 20k articles with 20k users... this surely wouldnt be advisable....

 

Does anyone have any thoughts of how to cover this?

 

Cookies I guess is one way, but its not very reliable or fool proof!

Link to comment
https://forums.phpfreaks.com/topic/74496-voting-system-preventing-duplicate-votes/
Share on other sites

Not to mention that a properly indexed MySQL database should be able to handle millions of records.  If you did manage to have so much data that performance really became an issue, you would want to look into maybe pre-calculation or load balancing.

ok perfect, thank you for the reassurance... I wanted to check that was the common way to do it and not just a quick fix...

 

there will be votes on articles, blog posts, images, profiles etc, so i guess I could make a seperate votes table for each category.

 

 

thanks for taking the time to post!

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.