I have an array Like
info['mk'] = 'hi';
info['pk'] = 'hello';
info['wk'] = 'hi';
info['rk'] = 'hello';
And i want to convert in json and send through ajax .
info = {}; //must be set 
info['mk'] = 'hi';
info['pk'] = 'hello';
info['wk'] = 'hi';
info['rk'] = 'hello';
then JSON.stringify(info);
JSON.stringify() only works on Object, not Array.
JSON.stringify()does not work on all browsers. See this