Why JSON ?

JSON, is an object string notation. For people who are familiar with the serialize function available in the scripting languages, JSON wouldn’t be anything new.

The reason for using JSON instead of the native php serialization is that JSON will work across languages. In other words, if we serialize something with PHP native serializer, and we want to deserialize it in Javascript or C# or Python, we can’t! But if we use JSON, all that is possible!

The advantage JSON provides over traditional XML or mere url notation output is that, with JSON all interactions happens via objects, and you don’t need to do any output parsing.

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s