Joke Collection Website - Public benefit messages - How to modify the ECSHOP registration page and set the mobile phone as a required item?

How to modify the ECSHOP registration page and set the mobile phone as a required item?

When the background sends a courier or sends a text message to the customer after receiving the advance payment, if the customer writes his home mobile phone or company phone number when registering, the background cannot send a text message directly to the customer. To solve this problem, you only need to limit the mobile phone to a required option when registering, and several places need to be modified!

Registration:

Find the language \ China \ user.php.

Find the following code:

* user_passport.dwt js language file */

$ _ lang ['passport _ js'] ['username _ empty'] ='-User name cannot be empty.' ;

$ _ lang ['passport _ js'] ['username _ shorter'] ='-User name cannot be less than 3 characters.' ;

$ _ lang ['passport _ js'] ['username _ invalid'] ='-User name can only be alphanumeric and underlined.' ;

$ _ lang ['passport _ js'] ['password _ empty'] ='-Login password cannot be empty.' ;

$ _ lang ['passport _ js'] ['password _ shorter'] ='-The login password cannot be less than 6 characters.' ;

$ _ lang ['passport _ js'] ['confirm _ password _ invalid'] ='-the passwords entered twice are inconsistent';

$ _ lang ['passport _ js'] ['email _ empty'] ='-email is empty';

$ _ lang ['passport _ js'] ['email _ invalid'] ='-email is not a legal address';

$ _ lang ['passport _ js'] ['agreement'] ='-You didn't accept the agreement';

$ _ lang ['passport _ js'] ['MSN _ invalid'] ='-MSN address is not a valid email address';

$ _ lang ['passport _ js'] ['QQ _ invalid'] ='-QQ number is not a valid number';

$ _ lang ['passport _ js'] ['home _ phone _ invalid'] ='-home phone is not a valid number';

$ _ lang ['passport _ js'] ['office _ phone _ invalid'] ='-the office phone number is not a valid number';

$ _ lang ['passport _ js'] ['mobile _ phone _ invalid'] ='-the mobile phone number is not a valid number';

$ _ lang ['passport _ js'] ['mobile _ phone _ empty'] ='-Mobile phone cannot be empty';

$ _ lang ['passport _ js'] ['msg _ un _ blank'] =' * User name cannot be empty';

$ _ lang ['passport _ js'] ['msg _ un _ length'] =' * The longest user name cannot exceed 7 Chinese characters';

$ _ lang ['passport _ js'] ['msg _ un _ format'] =' * User name contains illegal characters';

$ _ lang ['passport _ js'] ['msg _ un _ registered'] =' * User name already exists, please re-enter';

$ _ lang ['passport _ js'] ['msg _ can _ rg'] =' * can be registered';

$ _ lang ['passport _ js'] ['msg _ email _ blank'] =' * Email address cannot be empty';

$ _ lang ['passport _ js'] ['msg _ email _ registered'] =' * Email already exists, please re-enter';

$ _ lang ['passport _ js'] ['msg _ email _ format'] =' * Illegal email address';

Just enter $ _ lang ['passport _ js'] ['mobile _ phone _ invalid'] ='-the mobile phone number is not a valid number'; Just add the code in red above.

Step 2: Find user.js in js.

Find the following code:

if(mobile _ phone . length & gt; 0)

{

var reg = /^[\d|\-|\s]+$/;

If (! Registration Test (Mobile Phone))

{

msg+= mobile _ phone _ invalid+' \ n ';

}

}

if(msg . length & gt; 0)

{

Alarm (message);

Returns false

}

other

{

Return true

}

Add the following code before this code:

If (mobile phone length == 0)

{

msg+= mobile _ phone _ empty+' \ n ';

}

other

Then upload these two modified files, overwrite your original two files, and it's OK!