Store ajax json response into javascript variable using jQuery.
See also : http://stackoverflow.com/a/14220323