文章詳情頁
jquery清除input type為password?
瀏覽:157日期: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
相關文章:
1. mysql優化 - 關于mysql分區2. php laravel框架模型作用域3. node.js - 在vuejs-templates/webpack中dev-server.js里為什么要exports readyPromise?4. java - Atom中文問題5. java - MySQL中,使用聚合函數+for update會鎖表嗎?6. 請教各位大佬,瀏覽器點 提交實例為什么沒有反應7. javascript - ionic2 input autofocus 電腦成功,iOS手機鍵盤不彈出8. html5 - 如何實現帶陰影的不規則容器?9. css3 - 這個形狀使用CSS怎么寫出來?10. javascript - 為什么這個點擊事件需要點擊兩次才有效果
排行榜
