文章詳情頁
jquery清除input type為password?
瀏覽:110日期:2022-06-24 17:25:33
問題描述
我試了.val("")和.attr("value","")的方法,但沒有成功,對象獲取上沒問題的,因為用.attr成功改變了邊框顏色,求助??
問題解答
回答1:jquery清除input type為password?-PHP中文網問答-jquery清除input type為password?-PHP中文網問答
圍觀一下哦,學習一下。
回答2:可以試下
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <script src="jquery-2.1.1.min.js"></script> </head> <body ><input type="password" id="txtPwd" value="fsdafs"><script type="text/javascript">$(document).ready(function(){$("#txtPwd").attr("value","");});</script> </body></html>
標簽:
word
相關文章:
排行榜
