can anybody see where im going wrong here? Im trying to make a simple alert function when a button is clicked.
Okay so its working in jsFiddle but not on my website that HAS jQuery running:S
I have the following php...
if($interest1 != ''){
print $interest1 . "<a href='javascript:void(0);' class='deleteinterest'>delete</a><br />";
}
and in my AJAX.JS I have the following...
// Delete Interest Function
$(".deleteinterest").click(function()
{
alert('hello');
});
// End Delete Interest Function
Only this doesnt work?
You have mootools selected, try using jquery selection in the jsfiddle menu.
Fixed it for you: http://jsfiddle.net/jG9SQ/1/
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.