Bug Tracker

Modify

Ticket #3204 (closed bug: invalid)

Opened 5 years ago

Last modified 5 years ago

window.onunload event handler broken by jQuery("*") expression

Reported by: colonel Owned by:
Priority: major Milestone: 1.3
Component: core Version: 1.2.6
Keywords: Cc:
Blocking: Blocked by:

Description

seems like, at least for me, jquery can't parse a "*" selector expression properly.

the attached html is an html file with nothing but the jquery script include inside. on firefox 3 and IE7 it produces a nullpointer issue with var "m" which should be the matched quickClass regexp.

it works with 1.2.5, but fails in 1.2.6 -- and the only change that might cause this is the quickClass regexp change:

1.2.5: quickClass = new RegExp("(#.?)(" + chars + "*)"); 1.2.6: quickClass = new RegExp("(<#.>?)(" + chars + "*)");

Attachments

jquery-window-unload-regexp.zip Download (59.6 KB) - added by colonel 5 years ago.

Change History

Changed 5 years ago by colonel

comment:1 Changed 5 years ago by flesler

  • need changed from Review to Test Case
  • Milestone set to 1.3

Can you try adding a valid doctype ?

comment:2 Changed 5 years ago by colonel

added

<!DOCTYPE HTML PUBLIC "-W3CDTD HTML 4.01 TransitionalEN" " http://www.w3.org/TR/html4/loose.dtd">

still the same error -- you can't reproduce it on your machine, can you?

comment:3 Changed 5 years ago by colonel

Oh crap, that's my mistake. Seems like a global regex search n replace had messed up the jquery file (the quickClass regex!) I was using *doh*

sorry for bothering you, this ticket can be closed!

comment:4 Changed 5 years ago by flesler

  • Status changed from new to closed
  • Resolution set to invalid

Once you modify it, you lose the warranty :)

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.