doubi1931 2012-10-10 01:42
浏览 21
已采纳

如何只允许一个评级系统投票

guys i have made a jquery and css based star rating system. now i cant really think of way as how to save the user vote to database. and most importantly how to limit one user only to one vote.

since the number of visitors in the site is huge, i cant afford saving each user's ip to the database. and moreover i don't think it works good because even my ip address itself is dynamic. every time i disconnect and reconnect my internet my ip changes and i am able to vote again. so i don't think this will work.

this is what i have thought about saving the votes to the database: ill just save the number of votes a page has received and ill save the total rating of the page.

and ill divide the rating points with number of votes. so it will give me the average rating. right?

but i can think of no way to limit one user to one vote. please help.

  • 写回答

2条回答 默认 最新

  • dongxueji2838 2012-10-10 02:14
    关注

    There seems to be no practical way to strictly enforce one vote per person on the web.

    On computer networks, we often use surrogates for people. Some of them are

    • network or application login,
    • email address,
    • IP address,
    • cookies,

    and so on. But all of these have problems when it comes to one vote per person.

    • For web logins, a person can usually make multiple accounts. (Especially if they're free.)
    • Email accounts are free, and many (most?) people now have multiple email accounts.
    • IP addresses might work, but only on intranets (implemented with one IP address per computer) with unshared computers (company policy of one person per computer).
    • Cookies have the same problems as web logins. (And they can be deleted by the user.)

    If a vote is really valuable, some people will go to a lot of trouble to vote twice. But most votes aren't very valuable.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 Mac系统vs code使用phpstudy如何配置debug来调试php
  • ¥15 目前主流的音乐软件,像网易云音乐,QQ音乐他们的前端和后台部分是用的什么技术实现的?求解!
  • ¥60 pb数据库修改与连接
  • ¥15 spss统计中二分类变量和有序变量的相关性分析可以用kendall相关分析吗?
  • ¥15 拟通过pc下指令到安卓系统,如果追求响应速度,尽可能无延迟,是不是用安卓模拟器会优于实体的安卓手机?如果是,可以快多少毫秒?
  • ¥20 神经网络Sequential name=sequential, built=False
  • ¥16 Qphython 用xlrd读取excel报错
  • ¥15 单片机学习顺序问题!!
  • ¥15 ikuai客户端多拨vpn,重启总是有个别重拨不上
  • ¥20 关于#anlogic#sdram#的问题,如何解决?(关键词-performance)