Advanced input usage

Source: Internet
Author: User
1 . Remove the dotted box when the button is pressed
Add the attribute value hidefocus or hidefocus in input. = True  

2 . Read-only text box content
Add attribute values in input Readonly  

3 . Prevent text files from being cleared (style content can be referenced as a class)
< Input Style = Behavior: URL (# Default # Savehistory); Type = Text ID = Opersistinput >  

4 The. Enter key allows the cursor to move to the next input box.
< Input >  

5 . Can only be Chinese (with flashing)
< Input >  

6 . Can only be numbers (with flashing)
< Input >  

7 . Can only be a number (no flashing)
< Input Style = " IME-mode: Disabled " >  

8 . Only English and numbers can be entered (with flashing)
< Input >  

9 . Shielded Input Method
< Input type = " Text " Name = " URL " Style = " IME-mode: Disabled "   >  

10 . Only numbers can be entered, decimal point, minus ( - ) Character (no flashing)
< Input >  

11 . Only two decimal places can be entered, three decimal places (with flashing)
< Input maxlength = 9 ID = Text_kfxe name = Text_kfxe >  


------------------------------------------------------------------------
< Input type = " Text " Name = " Input1 " Value = " China " >

How to make the content in input read-only, that is, the user is not allowed to change the content.
< Input type = " Text " Name = " Input1 " Value = " China " . Blur () >
< Input type = " Text " Name = " Input1 " Value = " China "   Readonly >
< Input type = " Text " Name = " Input1 " Value = " China " Disabled >
We recommend that you do not use disabled. Otherwise, you will not be able to retrieve the value.
< Input type = " Text " Name = " Input1 " Value = " China " Read >
< Input type = " Text " Name = " Input1 " Value = " China "   Readonly Style = " Color: #999; " >

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.