I have a JSON data which is something like the following ::
{"product":["{productTitle=ABCD , productImage=/abcd.jpg, productPath=CDEF.html, productPrice=$299}","{productTitle=EFGH, productImage=xxxx.jpg, productPath=ggfft.html, productPrice=$299}"]}
I my JSP page I am trying to process the data and use it .
Following is the function that I am using to parse each node of the response .
success : function(data) {
alert("successs");
alert('data.product' + data.product);
$.each(data.product, function(index) {
alert(data.product[index].productTitle);
});
},
Here alert('data.product' + data.product); gives me the alert with the whole JSON which is under the product node .
alert(data.product[index].productTitle); -- This alert is showing as "undefined" .
I need help to parse it the JSON and print each of the "productTitle"
Thanks in advance .