| Server IP : 210.245.233.93 / Your IP : 216.73.216.226 Web Server : Apache/2.2.15 (CentOS) System : Linux webserver2.onesolution.com.hk 2.6.32-754.35.1.el6.x86_64 #1 SMP Sat Nov 7 12:42:14 UTC 2020 x86_64 User : apache ( 48) PHP Version : 5.3.3 Disable Function : exec, shell_exec, system, passthru, popen, proc_open, pcntl_exec MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/www/hkosl.com/survey_demo/ |
Upload File : |
<?php
require_once('webadmin/basic_info.php');
$id = (int)$_SESSION["id"];
$campaign = get_campaign($id);
check_campaign_date($campaign);
if(isset($_SESSION["telephone"])){
$tel = (int)$_SESSION["telephone"];
}else{
if(!isset($_POST["telephone"]) || empty($_POST["telephone"])){
echo "<script>alert('Please enter your mobile number.\\n請輸入你的手提電話號碼。'); history.back(); </script>";
exit;
}else{
if((int)$_POST["telephone"] != $_POST["telephone"]) {
echo "<script>alert('Please enter correct mobile number.\\n請輸入正確的手提電話號碼。'); history.back(); </script>";
exit;
}
}
$tel = (int)$_POST["telephone"];
}
//send sms
$url = $site_info["skytree_api_hostname"].'api/vip/requestSMSVerification?tel='.$tel;
$result = call_curl($url, NULL, 0);
$result_array = json_decode($result, true);
if($result_array["error"] == "0"){
if(isset($_SESSION["telephone"])){
echo "<script>location.href='registration_step1_verify.php?resend=1'; </script>";
}else{
$_SESSION["telephone"] = $tel;
echo "<script>alert('A verification sms message will send to your phone soon. Please wait a moment and activate your account later.\\n你將會收到認證的短訊,請稍等並進行認證。'); location.href='registration_step1_verify.php'; </script>";
}
}else{
if($result_array["errMsg"] == "vipAccountAlreadyExists"){
echo "<script>alert('This mobile phone has been used by someone. Please use another mobile phone to register account.\\n你所輸入的流動電話號碼已被登記。'); history.back(); </script>";
}else{
echo "<script>alert('The verification sms message cannot send out. Please try again.\\n認證短訊未能送出,請重新嘗試。'); history.back(); </script>";
}
}