您好我正在使用以下脚本更改按钮图像以在播放和停止之间切换:
<input type="image" src="../../Content/images/play.png" name="btn" style="width:22; height:22;" />
$(document).ready(function () {
$('#btn').bind("click", function () {
if ($(this).attr("scr") == "../../Content/images/play.png")
$(this).attr("scr", "../../Content/images/puase.png");
else
$(this).attr("scr", "../../Content/images/play.png");
});
});
它不起作用,将感谢您的建议。