Set default value of a password input so it can be read

前端 未结 5 1975
小鲜肉
小鲜肉 2020-12-11 16:42

I want to have a password field which says \"Password\" in it before a user enters their password (so they know what the field is)

I\'d rather just use Javascript, i

5条回答
  •  伪装坚强ぢ
    2020-12-11 17:32

    If you're using HTML5 then you should use the placeholder attribute.

    
    
    

    If you're using HTML4 you can create a fake password field.

    
    
    
    
    
    

提交回复
热议问题