Hi there,

I've activated anonymous voting. In the table votingapi_vote I've found at least 40 voting entries with nearly the same ip address: 66.249.71.xxx. I've looked it up at http://www.arin.net/whois/ and found out that this was the Google bot. We should add rel="nofollow" to the voting link or something like this.

Thanks, Bjoern

CommentFileSizeAuthor
#11 plus1_theming_improvement.patch9.79 KBvoxpelli
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Chill35’s picture

Assigned: Chill35 » Unassigned

That is a great idea. I will add the attribute now. Brb.

Chill35’s picture

Assigned: Unassigned » Chill35

Actually this will not work.

From Wikipedia

The nofollow attribute value is not meant for blocking access to content or preventing content to be indexed by search engines. The proper methods for blocking search engine spiders to access content on a website or for preventing them to include the content of a page in their index are the Robots Exclusion Standard (robots.txt) for blocking access and on page Meta Elements that are designed to specify on an individual page level what a search engine spider should or should not do with the content of the crawled page.

So what you have to do is edit the robots.txt file that comes with Drupal.

Add these lines:

Disallow: /plus1/vote/
Disallow: /?q=plus1/vote/

Report back on this, please. If that works, I will add it to the module's documentation.

Chill35’s picture

Assigned: Unassigned » Chill35

This might be a long term check of course. Please try it and report back in 2-3 weeks. That would be awesome!

Not many people use anonymous voting.

timmillwood’s picture

Any progress on this, I have been having the same problem on http://blog.to.it now that I have enabled anonymous voting.

Chill35’s picture

timmillwood, add the 2 lines to robots.txt. It really should fix the problem. And please report back if it does. I do not have a live site that uses plus 1. I cannot test this.

timmillwood’s picture

I have added those to the robot.txt but guess it will take a while to filter through.

Will that stop the listings on http://www.google.co.uk/search?q=site%3Ablog.to.it ?

Chill35’s picture

Will that stop the listings on http://www.google.co.uk/search?q=site%3Ablog.to.it ?

Yes.

voxpelli’s picture

Robots.txt and nofollow isn't the right solutions - the right solution is to not violate the HTTP-specification of the GET-method and submit votes through POST-request instead. A GET is not allowed to have any impact on the state of the data and letting a GET have that not only makes search engine robots trigger but can also have weird results with caches and similar.

asak’s picture

Any progress on this issue...?

voxpelli’s picture

I have coded in solutions to this in the themes for the sites I'm using Plus1 on - should be fairly easy to make a patch out of it when I get time.

If any one else has a solution - please don't let that stop you from presenting it though.

voxpelli’s picture

Title: Seams like vote link is executed by search engines » Vote link is executed by search engines
Version: 6.x-2.4 » 6.x-2.6
Assigned: Chill35 » Unassigned
Category: task » bug
Status: Active » Needs review
FileSize
9.79 KB

Here's a patch that changes the theme function as well as make it more customizable.

The change to the theme layer is that the link is now a button instead and the form POST:s the votes to the backend - which means that no search engines will index it and no cache will stop it from being processed.

This patch is dependent on #696500: Variable misused used to store state.

carlop’s picture

voxpelli this patch didn't work for me. I have this error

patching file README.txt
patching file jquery.plus1.js
patching file plus1.css
patching file plus1.module
Hunk #1 succeeded at 83 (offset 7 lines).
Hunk #2 succeeded at 259 (offset 5 lines).
Hunk #3 succeeded at 284 (offset 5 lines).
Hunk #4 FAILED at 288.
1 out of 4 hunks FAILED -- saving rejects to file plus1.module.rej

How i can fix this?

cashwilliams’s picture

I 2nd #12 as I get the same error trying to apply the patch.

Opps, you have to apply the other patch first, as it says in the description.

cashwilliams’s picture

Status: Needs review » Needs work

I've applied the patch, but it breaks the current version of google chrome. The submit button is shown but not clickable. (had a caching issue)

Everything is working and tested

cashwilliams’s picture

Status: Needs work » Reviewed & tested by the community
NancyDru’s picture

Status: Reviewed & tested by the community » Needs work

Coding standards: indentation, "elseif".

NancyDru’s picture

This also seems to fix the problem in #581032: Not working on IE8.

voxpelli’s picture

Do we need to reroll a patch for #16 or can we fix it once we commit?

NancyDru’s picture

It is fixed in my copy. Just waiting on commit access.

NancyDru’s picture

Status: Needs work » Patch (to be ported)
NancyDru’s picture

Status: Patch (to be ported) » Fixed

Committed to 6.x-2.x-dev.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.