EchoFool Posted January 8, 2011 Share Posted January 8, 2011 Hey i have an onclick call in a href to call an ajax function but it doesn't work for some reason. I use jquery library to use my ajax. The function: function dmg() { $.ajax({ type: "POST", url: "cm.php", async: false, data: "id="+$("#del"), }); $("#del").val(""); return false; } The link: <a href="?del=<?=$row['id']?>" onclick="dmg();">[x]</a> Have i got this incorrect with the use of GETs? Quote Link to comment https://forums.phpfreaks.com/topic/223804-function-wont-call/ Share on other sites More sharing options...
coffeecup Posted January 8, 2011 Share Posted January 8, 2011 the next forum topic after javascript is devoted to ajax. Quote Link to comment https://forums.phpfreaks.com/topic/223804-function-wont-call/#findComment-1156785 Share on other sites More sharing options...
EchoFool Posted January 8, 2011 Author Share Posted January 8, 2011 Oops i thought i posted it there - could a staff member please move this when they see it thanks! Quote Link to comment https://forums.phpfreaks.com/topic/223804-function-wont-call/#findComment-1156788 Share on other sites More sharing options...
Pikachu2000 Posted January 8, 2011 Share Posted January 8, 2011 Sure thing Quote Link to comment https://forums.phpfreaks.com/topic/223804-function-wont-call/#findComment-1156792 Share on other sites More sharing options...
EchoFool Posted January 8, 2011 Author Share Posted January 8, 2011 Thanks - hope some one can help Quote Link to comment https://forums.phpfreaks.com/topic/223804-function-wont-call/#findComment-1156796 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.