This is the JQuery code loaded over click but the callback function isn't working:
$.getJSON("load_img.php", {"id":"start"} , function(json){
alert(json);
});
PHP code gives me this output:
[
{"img_name":"shiva.jpg","img_id":"1"},
{"img_name":"shiva.jpg","img_id":"2"},
{"img_name":"Recoverd_jpg_file(4).jpg","img_id":"3"},
{"img_name":"Recoverd_jpg_file(542).jpg","img_id":"4"}
]
I cannot load any PHP pages from getJSON() function...i downloaded sample source code from [here][1]
[1]: http://www.sitepoint.com/ajaxjquery-getjson-simple/ and have run it on browser but it doesnt work still...
any help would be much appreciated!!!Thank you
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…