Skip to main content

Bug Tracker

Side navigation

#12321 closed bug (invalid)

Opened August 16, 2012 08:47PM UTC

Closed August 16, 2012 08:54PM UTC

Last modified August 16, 2012 09:11PM UTC

Error: Object doesn't support property or method if Object.prototype.extend is set and Quirks mode is used

Reported by: timb Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.8.0
Keywords: Cc:
Blocked by: Blocking:
Description

If you set Object.prototype.extend, certain jQuery functions will throw an exception. I have reproduced this with IE8 and IE9 when running in Quirks mode. This is new to 1.8.0.

Here is a jsFiddle that should allow you to reproduce the issue: http://jsfiddle.net/eGwNw/

It doesn't appear that jsFiddle allows you to use a doctype that will force quirks mode, so here's what you need to do:

1. Open the link in IE8 or IE9.

2. Press F12 to open the IE debugger.

3. Change Document Mode to Quirks Mode (you will get some errors from the jsFiddle site, as it's not meant to be run in Quirks Mode - just ignore them for now).

4. Press the Run button. You should get the error.

If you switch to jQuery 1.7.2 and run it, you will see that the issue no longer occurs.

Please note that older versions of Visual Studio (such as 2003) had the following default doctype:

<!DOCTYPE HTML PUBLIC "-W3CDTD HTML 4.0 TransitionalEN">

See here for more info:

http:aspnetresources.com/articles/doctype

When 4.0 Transitional is used and the system identifier has not be specified, it will force most (or all?) browser to use Quirks Mode (source: http://en.wikipedia.org/wiki/Quirks_mode). The same occurs if 4.01 transitional is used without the system identifier. Therefore, there may be a number of legacy applications out there that would be impacted by this breaking change if they were to use jQuery 1.8.0.

Attachments (0)
Change History (3)

Changed August 16, 2012 08:54PM UTC by timmywil comment:1

resolution: → invalid
status: newclosed

jQuery does not support changing native prototypes or quirksmode.

Changed August 16, 2012 09:10PM UTC by timb comment:2

I apologize for reporting this. I wasn't aware that jQuery does not support changing native prototypes or quirksmode (although I can completely understand why it wouldn't).

I just did a search for this and found the following: http://docs.jquery.com/Won't_Fix.

I checked the bug reporting guidelines, but I did not see any link to this. I recommend that a link to the Won't Fix page be put on the New Ticket page or on the bug reporting guidelines page to help prevent this from happening again in the future.

Changed August 16, 2012 09:11PM UTC by dmethvin comment:3

Good point, we should have the wontfix links in the reporting page. Thanks!