如何向超链接添加Javascript提醒? 我想在有人点击链接时弹出警报。 这是现在的剧本 -将javascript添加到超链接
<a href="<?php echo ($link1);?>" onclick="popitup();" data-role="button" data-theme="b" data-inline="true" > Send </a>
,我想将它添加到链接
<script type="text/javascript">alert('Text.');</script>
Darin的解决方案可能是更好尽管编写javascript in-line是不好的做法。 – lifetimes