Giter Site home page Giter Site logo

Vote won't go above 2 about recommended-links HOT 9 CLOSED

dldahly avatar dldahly commented on September 26, 2024
Vote won't go above 2

from recommended-links.

Comments (9)

goldenapples avatar goldenapples commented on September 26, 2024

Each user can only vote once on any link or comment, so the maximum score any item could reach if you're testing your own site is 2 (1 point for the initial submission + 1 upvote).

Other people have mentioned that the way the plugin handles votes from non-logged-in users is a bit screwy, but as of now I haven't figured out a better way of doing it. Basically, if a non-logged-in user attempts to vote, the plugin checks to make sure there haven't been any votes on that item from the same IP address and only saves the vote if its the first vote from that IP address.

Could that explain the issue you're having?

from recommended-links.

dldahly avatar dldahly commented on September 26, 2024

Thanks for the quick reply, but I tried from another machine, logged out, and it wouldn't vote. Plus I've had about 50 visits to the site with no new votes showing up.

All the best,

DL

Darren L Dahly, PhD
University of Leeds
Centre for Epidemiology and Biostatistics
Africa College (www.africacollege.leeds.ac.uk)

+44 (0)113 343 8909
[email protected]
http://statisticalepidemiology.org
@statsepi

On 24 May 2012, at 17:35, "Nathaniel Taintor" [email protected] wrote:

Each user can only vote once on any link or comment, so the maximum score any item could reach if you're testing your own site is 2 (1 point for the initial submission + 1 upvote).

Other people have mentioned that the way the plugin handles votes from non-logged-in users is a bit screwy, but as of now I haven't figured out a better way of doing it. Basically, if a non-logged-in user attempts to vote, the plugin checks to make sure there haven't been any votes on that item from the same IP address and only saves the vote if its the first vote from that IP address.

Could that explain the issue you're having?


Reply to this email directly or view it on GitHub:
#14 (comment)

from recommended-links.

goldenapples avatar goldenapples commented on September 26, 2024

You're right! I looked at your site, and wasn't able to upvote any of the links past 2.

That's weird. I haven't seen that issue before. Will have to investigate and figure out why that could be happening.

from recommended-links.

dldahly avatar dldahly commented on September 26, 2024

The update did not resolve the issue. I also tried disabling comments on the page but that didn't help. I'm not sure if it's related, but when I vote, it counts for 2. So if I down vote a reclink that's at +1, it goes to -1. I can repeatedly vote on all of the entries, but never beyond +/-2. Also, if a vote is on -1 (for example), and I down vote it, nothing happens because my vote=2 and -1-2=-3, which is <-2. I hope this is helpful.

from recommended-links.

goldenapples avatar goldenapples commented on September 26, 2024

It sounds like for some reason the plugin is interpreting all votes on the site as being from you. So if a link was at a score of 1 and you downvote it, it removes the previous upvote from you (because a user can only vote once per article), changing the vote from +1 to -1. Why the current_user function is always returning you, I don't know. Will get a copy of the theme you're using and see if I can't figure out what's going on.

from recommended-links.

dldahly avatar dldahly commented on September 26, 2024

Hi - I don't want to be a pest, but thought I would follow up to see if you had figured anything out. Thanks.

from recommended-links.

dldahly avatar dldahly commented on September 26, 2024

Hi again. I think I might have figured out what the problem is.

I changed themes (to the standard WP theme) deleted all my reclinks, and reinstalled the plugin. The problem was the same. However, I can get the vote higher if I use registered usernames on the site (which I hadn't tried before). However, if I try to vote while not logged in, the vote won't increase, regardless of the machine or IP being used. Thus I suspect that the plugin is somehow only allowing 1 "unregistered" vote per reclink....just a thought. It's still a great plugin, I still haven't seen anything like it, and I hope you keep working on it.

from recommended-links.

goldenapples avatar goldenapples commented on September 26, 2024

Ah! That definitely explains the problem. Thanks... I was able to track it down with that bit of info. I'm working a few more bugfixes and enhancements in before releasing a new version on wordpress.org, but the trunk download here should be fixed for you.

from recommended-links.

dldahly avatar dldahly commented on September 26, 2024

I fixed the typo (user_ip -> userip) but it hasn't fixed the problem. FYI.

from recommended-links.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.