On 10/10/06, Klaus Hartl <[EMAIL PROTECTED]> wrote:
> > One last XML related fix I've found within jQuery. When using Xpath
> > expressions, jQuery has a custom expression which allows matching
> > against the content of an element, such as $("p:contains('test')"),
> > which will match all <p> tags which contain text in their body. Once
> > again, IE has trouble with this when processing it in an XML context.
> > The fix is simple, change this line (~line 520):
> >
> > contains: "(a.innerText||a.innerHTML).indexOf(m[3])>=0",
> >
> > to this:
> >
> > contains: "((a.firstChild &&
> > a.firstChild.nodeValue)||a.innerText||a.innerHTML).indexOf(m[3])>=0",
>
> Does this work in Firefox with text nodes that start on a new line?
>
> <item>
>      Text node
> </item>

Seems to work for me in Firefox for a couple of test cases I made just
now to test the new line functionality.

I've also done a bit of testing in Safari just now, and the results
are similar, namely everything's working fine with the changes applied
to the latest SVN. I may work on compiling some formal test cases for
this functionality tonight or tomorrow sometime.

~Peter Woods

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to