fix variable sms_otp_registration
This commit is contained in:
parent
005155e2a5
commit
3febb60253
@ -22,7 +22,7 @@ switch ($do) {
|
|||||||
$password = _post('password');
|
$password = _post('password');
|
||||||
$cpassword = _post('cpassword');
|
$cpassword = _post('cpassword');
|
||||||
$address = _post('address');
|
$address = _post('address');
|
||||||
if (!empty($config['sms_url']) && $_c['allow_phone_otp'] == 'yes') {
|
if (!empty($config['sms_url']) && $_c['sms_otp_registration'] == 'yes') {
|
||||||
$phonenumber = Lang::phoneFormat($username);
|
$phonenumber = Lang::phoneFormat($username);
|
||||||
$username = $phonenumber;
|
$username = $phonenumber;
|
||||||
} else if (strlen($username) < 21) {
|
} else if (strlen($username) < 21) {
|
||||||
@ -45,7 +45,7 @@ switch ($do) {
|
|||||||
$msg .= Lang::T('Passwords does not match') . '<br>';
|
$msg .= Lang::T('Passwords does not match') . '<br>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($config['sms_url']) && $_c['allow_phone_otp'] == 'yes') {
|
if (!empty($config['sms_url']) && $_c['sms_otp_registration'] == 'yes') {
|
||||||
$otpPath .= sha1($username . $db_pass) . ".txt";
|
$otpPath .= sha1($username . $db_pass) . ".txt";
|
||||||
run_hook('validate_otp'); #HOOK
|
run_hook('validate_otp'); #HOOK
|
||||||
//expired 10 minutes
|
//expired 10 minutes
|
||||||
@ -114,7 +114,7 @@ switch ($do) {
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
if (!empty($config['sms_url']) && $_c['allow_phone_otp'] == 'yes') {
|
if (!empty($config['sms_url']) && $_c['sms_otp_registration'] == 'yes') {
|
||||||
$username = _post('username');
|
$username = _post('username');
|
||||||
if (!empty($username)) {
|
if (!empty($username)) {
|
||||||
$d = ORM::for_table('tbl_customers')->where('username', $username)->find_one();
|
$d = ORM::for_table('tbl_customers')->where('username', $username)->find_one();
|
||||||
|
@ -212,11 +212,11 @@
|
|||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-md-2 control-label">{Lang::T('SMS OTP Registration')}</label>
|
<label class="col-md-2 control-label">{Lang::T('SMS OTP Registration')}</label>
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<select name="allow_phone_otp" id="allow_phone_otp" class="form-control">
|
<select name="sms_otp_registration" id="sms_otp_registration" class="form-control">
|
||||||
<option value="no">
|
<option value="no">
|
||||||
{Lang::T('No')}
|
{Lang::T('No')}
|
||||||
</option>
|
</option>
|
||||||
<option value="yes" {if $_c['allow_phone_otp']=='yes' }selected="selected" {/if}>
|
<option value="yes" {if $_c['sms_otp_registration']=='yes' }selected="selected" {/if}>
|
||||||
{Lang::T('Yes')}
|
{Lang::T('Yes')}
|
||||||
</option>
|
</option>
|
||||||
</select>
|
</select>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user