function change() {
var img=document.getElementById("verifyCode");
img.src="${pageContext.request.contextPath}/varifyCode.action?"+new Date().getTime();
alert(img.src);
}
img id="varifyCode" class=" captchaImage" src="${pageContext.request.contextPath}/verifyCode.action" onclick="change()"
jsp中使用标签img中onclick没有反应
- 写回答
- 好问题 0 提建议
- 关注问题
- 邀请回答
-
3条回答 默认 最新
斯洛文尼亚旅游 2017-02-07 03:37关注action名字都错了。。自己好好对比看看。。。verifyCode...varifyCode
src="${pageContext.request.contextPath}/verifyCode.action" img.src="${pageContext.request.contextPath}/varifyCode.action?"+new Date().getTime();本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报