By sowmithrii on
I need to enable voting for anonymous users in a poll.
For this I created a poll with few choices and when I was logged in as admin, am able to vote and the database is updated.
When I am logged out I am unable to vote as the page is just displaying the total votes instead of vote button.
I tried enabling the permissions for anonymous users under Administer > permissions > poll module, but no change in the page.
I disabled the caching from Administer > site configuration > performance, still no vote button for anonymous users.
Any hints are greatly appreciated. Thanks in advance.
Comments
any luck?
Hi - I am having the same issue with this module - once I've voted as an anonymous user it just displays the results page no matter how much cache clearing I do. Bit of a flaw...
need help
I have same issue too.
Voting is limited to one vote per ip address
As you can see by peeking into poll.module (row 407), voting is limited per IP address by design. There is no better method to prevent abuses than using ip restrictions. It has been recognized to be a problem in some cases, for instance with many institutional users since outgoing internet connections are masked as the same IP address.
I struggled with this same issue for a while before eventually writing a contrib module for alternative approach. Please try using the Poll Enhancements module, which restricts voting using cookies. Thus you may vote multiple times using different browser each time. Or by clearing cookies in between. (Actually there's a lightweight abuse prevention based on ip address - configurable on module's settings page).
As was mentioned previously
As was mentioned previously the issue is related to the IP check inside poll module. Most likely that on your dev box you point local domain to 127.0.0.1 so because of it you can vote just once.
The othet thing related to IP check could be that you running some kind of reverse proxy which will pass requests with the same proxy IP.
You can check http://api.drupal.org/api/drupal/in focludes--bootstrap.inc/function/ip_address/6 for more information. Basically you may need to define your reverse proxy ip in settings.php to solve IP problem.