WOW, thanks for that link to debugbar.com -- I had been searching far and wide for an IE debugger and couldn't find anything good -- that is sweet!

-- Josh

----- Original Message ----- From: "Rob Wilkerson" <[EMAIL PROTECTED]>
To: "jQuery (English)" <jquery-en@googlegroups.com>
Sent: Tuesday, November 20, 2007 11:51 AM
Subject: [jQuery] Re: Selector Not Working in IE7?




On Nov 16, 1:33 pm, Rob Wilkerson <[EMAIL PROTECTED]> wrote:
I'm trying to "manually" interact with the multifile plugin and, as
part of that endeavor, I need to systemically access the anchor tag
that provides "Delete" functionality.  The following works great in FF
(of course):

$('a[href^="#multimulti_"]')

The objects are returned as expected and alert ( $
('a[href^="#multimulti_"]').length ) returns the expected number of
elements.  In IE7, though, the former value is undefined and the
latter is 0.  Anyone have any idea why this might be happening?

For anyone who may be interested and searching, I finally tracked this
down thanks to the most excellent DebugBar (http://
www.debugbar.com/).

Seems that IE, in its infinite wisdom, thinks that the hrefs created
by the multifile upload code aren't good enough and prepends the rest
of the page URI to them at runtime. The href coded "<a
href="#multimulti_0">Delete</a>", rendered in IE, is transformed into
"<a href="http://www.mydomain.com/survey#multimulti_0";>Delete</a>".

As a result, the attribute-begins-with selector ([attribute^=value])
doesn't work. I replaced it with the attribute-contains selector
([attribute*=value]) so that the code will work in both IE & Firefox.

Reply via email to