Skip to main content

Bug Tracker

Side navigation

#6962 closed bug (invalid)

Opened August 27, 2010 06:53PM UTC

Closed August 28, 2010 02:28AM UTC

JQuery Crashes On Certain Styles Of HTML

Reported by: TheFerrett Owned by:
Priority: Milestone: 1.4.3
Component: unfiled Version: 1.4.2
Keywords: Cc:
Blocked by: Blocking:
Description

We've been using jQuery on our site for some time today, when I got an email from my boss telling me that the card popups we have weren't working on one page.

When viewed in Firebug, that page (AND NO OTHER PAGE) showed me that jQuery had crashed on line 1526 with the following error:

"String contains an invalid character" code: "5""

The line that causes the crash is " elem.setAttribute( name, "" + value ); "

This bug doesn't appear on any other page in our site (we have thousands) - and Googling "String contains an invalid character code: jquery" shows several pages of people who've experienced similarly inexplicable crashes.

The page that's causing the issue can be found here:

http://www.starcitygames.com/magic/misc/19948_Innovations_A_Tournament_Report_You_Will_Remember.html

And you may note that a similar article here, using the same HTML template (which, yes, does not validate), runs jQuery perfectly.

http://www.starcitygames.com/magic/misc/19949_The_Dragonmasters_Lair_My_Nationals_Report.html

Something in the HTML of one page is causing jQuery to choke. I've done a couple of switches (changing the title and description, et al), and I haven't been able to get jQuery to run. But I was hoping maybe someone with more experience in jQuery could dope this out.

Attachments (0)
Change History (1)

Changed August 28, 2010 02:28AM UTC by dmethvin comment:1

resolution: → invalid
status: newclosed

Google tells me this:

http://www.devcomments.com/Problem-with-attr-function-attempting-to-set-attribute-values-to-JS-functions-at57782.htm

If your code (or code you include via a library) is adding new properties to Object it might cause a problem like this. None of the jQuery or jQuery UI code does this.