Show and hide passwords

Source: Internet
Author: User
Tags microsoft frontpage

<Html>

<Head>
<Meta http-equiv = "Content-Type" content = "text/html; charset = gb2312">
<Meta name = "GENERATOR" content = "Microsoft FrontPage 4.0">
<Meta name = "ProgId" content = "FrontPage. Editor. Document">
<Title> show and hide passwords-www.51windows. Net </title>
<Style>
Body, input {font: menu}
</Style>
</Head>
<Body>
<Form method = "POST" action = "addcheck. asp" name = "forms">
<Span id = box> <input type = "password" name = "password" size = "20" value = "51windows.com"> </span>
<Span id = click> <a href = "javascript: ps ()"> display password </a> </span>
<Script language = "JavaScript">
<! --51windows.com: haiwa -->
Function ps (){
If (this. forms. password. type = "password ")
Box. innerHTML = "<input type = \" html \ "name = \" password \ "size = \" 20 \ "value =" + this. forms. password. value + "> ";
Click. innerHTML = "<a href = \" javascript: txt () \ "> hide password </a> "}
Function txt (){
If (this. forms. password. type = "text ")
Box. innerHTML = "<input type = \" password \ "name = \" password \ "size = \" 20 \ "value =" + this. forms. password. value + "> ";
Click. innerHTML = "<a href = \" javascript: ps () \ "> display password </a> "}
</Script> </form>
<Script>
Function help (){
Title = "show and hide passwords"
Time = "23:17 2002-8-17"
Tips = "display and hide the password in input, and change it to the type value of input dynamically. Two input boxes will not be used when prompted for registration :)"
Info = "\ nwww.51windows.com \ n doll: jimao8@163.com"
Alert (title + "\ n (" + time + ") \ n" + tips + "\ n" + info )}
Document. write ("<button style = 'font: menu; position: absolute; top: 20; right: 10; 'onclick = help ();> Help </button> ");
Document. write ("<button style = 'font: menu; position: absolute; top: 20; right: 50; 'onclick = window. location = 'view-source: '+ window. location. href;> source file </button> ")
</Script>
</Body>
</Html>

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.