39
rated 0 times
[
40]
[
1]
/ answers: 1 / hits: 46367
/ 12 Years ago, tue, november 27, 2012, 12:00:00
I'm using simple links for an admin panel but in case of user accidently clicks on link for user deletion, there should be a confirmation pop-up for avoding this.
Probably as you know a href tag's are not fully compatible with javascript. So, i have used span tag for onclick but that didn't went so well:
<script type=text/javascript>
function confirm_click()
{
return confirm(Are you sure ?);
}
</script>
Here is the html code for link:
<span onclick=confirm_click();> <a title=Delete User href=http://www.google.com><i class=icon-remove-sign>DELETE</i></a></span>
More From » html