-2

I want to know about the clients who use my web site are they already voted or not.
Like for a star Rating system. So what is the best technique to find this?

  1. Using Cookies?
  2. Using save the IP address?
  3. any other technique?
Ram
  • 143,282
  • 16
  • 168
  • 197
Hashan
  • 656
  • 1
  • 8
  • 20

1 Answers1

0

The risks you run with each:

  1. Using Cookies - savvy users will clear their cookies and vote again (and again and again..)
  2. Saving the IP on the server - corporate visitors coming from a NAT'd address may be stymied as another coworker may have already voted from that IP address.

How important is it to avoid the fraud in option 1? If you have the means to "discount" excessive votes from a single IP address (i.e. cleanse vote records where total # from a given IP exceed some threshold), then cookies would be easiest and most widely accepted. Alternatively, you can use a combination of cookie and localStorage to further deter those who wish to over-vote.

Forty3
  • 2,199
  • 1
  • 14
  • 19