<type script = "text/javascript" bahasa = "javascript"> var tunggu = 60; function change () {$ o = $ ("#j_refresh_checkcode"); if (tunggu == 0) {$ o.removeattr ("Disabled"); $ o.html ("tidak bisa melihat dengan jelas? Ubah yang lain"); tunggu = 60; } else {$ o.attr ("dinonaktifkan", true); $ o.attr ("font-color", "grey"); $ o.html (tunggu + "dapat dikelola kembali dalam hitungan detik"); Tunggu--; if (tunggu == 59) {var imGnode = document.geteLementById ("vimg"); imgnode.src = "../../AjaxServer/CheckCodepic.ashx?t=" + (tanggal baru ()). ValueOf (); // Tambahkan parameter waktu di sini untuk mencegah masalah caching browser $ ("#j_checkcode_tip"). AddClass ("hide"); $ ("#J_checkcode_tip> div"). Html (""); $ ("#<%= hidpicMessage.clientId%>"). Val (""); } setTimeout (function () {ubah ()}, 1000)}} </script>Maka HTML adalah sebagai berikut:
<SEV> <SPAN> kode verifikasi </span> <input name = "checkCode" id = "j_checkcode_input" onmousedown = "clearcodemessage ()" type = "text" maxlength = "6" autocomplete = "off" onblur = "checkCode ()"//<img src = ".." id="vimg" style="float:left;margin:-1px 0 0 3px"/> <a id="J_refresh_checkcode" onclick="change()">Can't see clearly, change another</a> <div id="J_checkcode_tip"> <div> <i></i> <div> </div> </div> </div> </div> </div> </div> </div>