UI Deploy

Curated, Short, Web UI Dev we Love.

Send HTML Form Data as JSON via Ajax

There’s a lot of confusion among new developers on which format data should be sent to server.  Some dev’s create data string manually and some use jQuery’s API methods .serialize() and .serializeArray(). Our last tutorial shows how to use serializeArray() method to send array of objects to server via Ajax. Now taking it further what if I’d want to send JSON data to server, in this post I will be doing that. this post is just a guide to all new developers understand how to leverage JSON in exchanging data between client and server.

view source

Advertisement