TinyMCE:API/tinymce.util.JSON

From Moxiecode Documentation Wiki

Jump to: navigation, search

Class: tinymce.util.JSON (static)

JSON parser and serializer class. This class is a singleton so you call all methods without creating an instance of the JSON object.

Methods

parse
Unserializes/parses the specified JSON string into a object.
serialize
Serializes the specified object as a JSON string.

Examples

// JSON parse a string into an object
var obj = tinymce.util.JSON.parse(somestring);

// JSON serialize a object into an string
var str = tinymce.util.JSON.serialize(obj);
Personal tools