Tag Archives: ajax

Include ajax in wordpress using jquery?

To include ajax in wordpress plugin:- for eg. if we want to use ajax on click of some event <div id=”ajaxid” onclick=”testfn(1)” /> <script type=”text/javascript”> function testfn(val) { jQuery.ajax({ type: “post”,url: “admin-ajax.php”,data: { action: ‘save_data’, val: val}, success: function(html){ //so, … Continue reading

Posted in jquery, WordPress | Tagged , , | 1 Comment