ones, and serialize it out to a string.
Object string. What's the use of that, you might ask? Well imagine you created a
do that is unclear, but just say you had your reasons. When people add objects
thing and store the string a cookie. Then on every page load you could check if the
on it. Then when you're ready to post it back to the server you can serialize
it as an XML string and post that file. I was going to write an example of this but
you'll have to make do with the demo below.
plug in SerializerJS.js or Serializer.XML which adds in the GetJSString() and
GetXMLString() methods automatically. It's split up like this as you could add in
differnet formatters later. The obvious one to write would be GetHTMLString()
but I haven't done that.
This code is inspired by JSON
but it would be a mistake to think of it as the same thing. JSON makes no note
an object, even noting if a string was created literally or using the 'String'
There are some obvious
applications for interplay with Ajax here that hopefully someone will fully
things to do.
I've used the Serializer on this site in a few places. The
URLs are created using it, and the CSS Scrollbar
values are stored to a cookie
If you want to play around with the files then you can download the zip files
and if you build a good demo then please send us a copy. The files should work on all
Don't try and serialize the serializer object, it'll just make your head hurt.