NoScript forces display of hidden <a>

Bug reports and enhancement requests
Post Reply
kristjan
Posts: 2
Joined: Wed Jul 13, 2011 1:59 pm

NoScript forces display of hidden <a>

Post by kristjan »

NoScript versions I've tested: 2.1.2.1rc1 (FF 5.0), 2.1.1.2 (FF 3.6.18)

Demo: http://keku.mit.edu/noscript_test.php

Expected result:
Scripts enabled: the text "google - javascript enabled"
Scripts disabled: the text "testing. you shouldn't see a link."

Observed result:
Scripts enabled: the text "google - javascript enabled"
Scripts disabled: the text "testing. you shouldn't see a link.
google" (this is the <a> element that shouldn't be displayed)

Notice that if you select the whole page when scripts are disabled using NoScript and use "View selection source", you see two <a> elements, one being the original link and the other inserted before the closing </body> tag:

Code: Select all

<a style="visibility: visible; display: block;" href="http://google.com">google</a>
This second link should not be there.

I've tried just disabling scripts on a Firefox profile with no addons and got the expected result so this must be a NoScript bug.
Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20110706 Firefox/5.0
dhouwn
Bug Buster
Posts: 968
Joined: Thu Mar 19, 2009 12:51 pm

Re: NoScript forces display of hidden <a>

Post by dhouwn »

Might the "Attempt to fix JavaScript links" feature be involved in this?

/edit: Nope, apparently not, unchecking the checkbox for it and reloading doesn't change a thing in this case.
Last edited by dhouwn on Wed Jul 13, 2011 2:39 pm, edited 1 time in total.
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0
User avatar
Giorgio Maone
Site Admin
Posts: 9527
Joined: Wed Mar 18, 2009 11:22 pm
Location: Palermo - Italy
Contact:

Re: NoScript forces display of hidden <a>

Post by Giorgio Maone »

It's a feature, not a bug.
Mozilla/5.0 (Windows NT 5.2; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0
kristjan
Posts: 2
Joined: Wed Jul 13, 2011 1:59 pm

Re: NoScript forces display of hidden <a>

Post by kristjan »

Alright, thanks for the quick reply!
Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20110706 Firefox/5.0
Post Reply