Issues with SPServices and jQuery 1.5

<UPDATE date=”2010-02-09″>
In all of my testing since I posted this, the z:row notation issue seems to be the only issue with jQuery 1.5 and SPServices. I’ve got this fixed in my alpha of v0.6.0, which I hope to release soon. However, in your own code, be sure to add the single quotes! Also see my follow up post.
</UPDATE>

I wanted to do a quick post to let anyone who is following along at home that for the moment, SPServices will not work with jQuery 1.5. I’m hoping that this is a temporary thing and I will be able to fix it for the v0.6.0 release.

The one issue that I know about at the moment is that this syntax no longer seems to work:

$(xData.responseXML).find("[nodeName=z:row]").each(function() {

Perhaps I’ve been a bit lazy about it, but if you look around, lots of others have been, too. Adding quotes around the ‘z:row’ value seems to fix it.

$(xData.responseXML).find("[nodeName='z:row']").each(function() {

I’ll be doing more testing, of course, but for the time being, stick with jQuery 1.4.x with SPServices.

Similar Posts

7 Comments

    1. If you’re interested in doing some testing with jQuery 1.5 and SPServices v0.6.0ALPHA8, that would be awesome. I just posted v0.6.0ALPHA8 with the ‘z:row’ fix included. Any regression testing with jQuery 1.4.x would be cool, too, but I don’t expect that this change will cause a downward issue. Hey, you asked what you could do to help!

      It was lonely up there, anyway.

      M.

    2. Mark, are we talking about the same guy? The guy who – does thorough testing of the code he makes available for free – is ready to acknowledge that he may have made a mistake – immediately sends out an alert to make sure nobody gets hurt – will work on it until the issue is resolved?
      Well, your call ;-)

    1. Thanks, Matt. It sounds like the quotes were required all along but that jQuery 1.4.4 and below were lax in enforcing it and now they are truly required. That’s actually a good thing, even if it does make some of my historical code invalid.

      M.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.