WeChat applet (17) input component details

Source: Internet
Author: User
This article mainly introduces the detailed information about the input component of the applet. For more information, see

The input box is frequently used... If the style is used, you can customize a view. There are not many input attributes. you need to test them slowly and try again.

Main Attributes:

Wxml

 
 
  
  
 
  
   Login

Js

Page ({/*** initialization data */data: {phone: '', password:'',},/*** enter the listening mobile phone number */listenerPhoneInput: function (e) {this. data. phone = e. detail. value;},/*** listen for password input */listenerPasswordInput: function (e) {this. data. password = e. detail. value;},/*** listener logon button */listenerLogin: function () {// Print the revenue account and password console. log ('mobile phone number: ', this. data. phone); console. log ('password: ', this. data. password) ;}, onLoad: function (options) {// parameters brought about by page navigation during page initialization options}, onReady: function () {// page rendering completed }, onShow: function () {// page display}, onHide: function () {// page hide}, onUnload: function () {// page close }})

Wxss

.input{ padding-left: 10px; height: 44px;} .inputView{ border: 2px solid red; border-radius: 40px; margin-left: 15px; margin-right: 15px; margin-top: 15px;}

For more information about the input component of mini programs (17th), refer to the PHP Chinese website!

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.