Spry 1.4: Spry.utils.updateContent

Another cool new feature of Spry 1.4, and I don't even have to write a blog entry on it. Bruce Phillips has a blog entry and demo showing off this new feature. At a basic level it gives you a super simple function to change the content of a element with another URL. So an example, if foo was an element, this would replace it with another URL:

Spry.Utils.updateContent('foo', 'mynewdata.cfm');

You can even fire off a function automatically when the data is downloading.

Archived Comments

Comment 1 by DK posted on 12/18/2006 at 12:03 AM

this one is one i'm really excited about as its primary what I crutch to using Ajax for and while spry has a lot of nice addons there wasn't a lynchpin till now (for me)

Comment 2 by Bruce posted on 12/18/2006 at 5:38 AM

Ray:

Thanks for the plug. Your blog is leading the way in helping developers understand the power and ease of use of Spry. The Spry 1.4 release provides alot of capabilities.

Comment 3 by Johh Allen posted on 12/18/2006 at 6:42 AM

SOOOOO easy! It works for event=whatEverFrameworkEvent+CorrespondingView totally! YEA!!

RC, thanks MUCHO!
ja

Comment 4 by Raymond Camden posted on 12/18/2006 at 6:46 AM

Thank Bruce. His example is definitely nice!

Comment 5 by DK posted on 12/18/2006 at 9:53 PM

another nice one is the addition of the innerhtml

<code>Spry.Utils.setInnerHTML()</code>

the local content version of updateContent. 1.4 just keeps getting betterthe deeper you go.