Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/402.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript html中的密码字段隐藏选项_Javascript_Html_Xhtml_Html5 Canvas - Fatal编程技术网

Javascript html中的密码字段隐藏选项

Javascript html中的密码字段隐藏选项,javascript,html,xhtml,html5-canvas,Javascript,Html,Xhtml,Html5 Canvas,对于我的HTML密码文本框,我使用了输入类型作为密码输入,但我能够看到输入的密码是什么在任何情况下,我们都不能看到在密码输入中键入的内容。 有人能建议我如何解决这个问题吗?尝试我下面的代码,复制到一个.TXT文件中,另存为.HTML,并在Firefox或IE中打开此HTML以复制问题 这是我的问题代码: <htm l> <form id="login" method="post" action="index.html"> <div style="wi

对于我的HTML密码文本框,我使用了输入类型作为密码输入,但我能够看到输入的密码是什么在任何情况下,我们都不能看到在密码输入中键入的内容。

有人能建议我如何解决这个问题吗?尝试我下面的代码,复制到一个.TXT文件中,另存为.HTML,并在Firefox或IE中打开此HTML以复制问题

这是我的问题代码:

<htm l>
    <form id="login" method="post" action="index.html">
    <div style="width: 450px; height: 250px; background: blue;BORDER=8"><br/><br/><br/>
    &nbsp;<strong>Username: </strong>&nbsp; <input type="text" name="userid" size="18" maxlength="18"/><br/>&nbsp;<br/>
    &nbsp;<strong>Password : </strong> &nbsp; <input type="password " name="pswrd" size="18" maxlength="18"/>&nbsp;<br/><br/><br/>&nbsp;&nbsp;

    <input type="submit" value="Submit"> &nbsp;&nbsp;
    <input type="reset" value="Cancel" onclick="myFunction()" value="Reset form"/> &nbsp;&nbsp;&nbsp 
    &nbsp;</div><br/><br/></html>




用户名:

密码:


 


好的,在
type=“password”



移除它。它可以正常工作。

删除类型参数后密码后面的空格。

删除中的空格 type=“密码” 所以,应该是这样 type=“密码”


如果html不理解任何类型,如“password”,则它假定元素为text类型

删除type=“password”中的空格
<input type="password" name="pswrd" size="18" maxlength="18"/>