Register for your free account! | Forgot your password?

You last visited: Today at 12:38

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Release] SSN Online website (for vsro)

Discussion on [Release] SSN Online website (for vsro) within the SRO PServer Guides & Releases forum part of the SRO Private Server category.

Reply
 
Old 08/13/2019, 14:33   #46
 
B1Q's Avatar
 
elite*gold: 350
Join Date: Aug 2015
Posts: 1,999
Received Thanks: 1,188
Quote:
Originally Posted by ThievesUTD View Post
Apache works, MariaDB works, MySQL doesnt..., i installed mysql server 8.0, and i went to services and saw WAMPACHE AND WAMPMARIA BOTH STATUS RUNNING. BUT when i want start WAMPMYSQLD64 it says: THE WAMPMYSQLD64 SERVICE ON LOCAL COMPUTER STARTED AND THEN STOPPED. SOME SERVICES STOP AUTOMATICALLY IS THEY ARE NOT IN USE BY OTHER SERVICES OR PROGRAMS.

World Wide Web Publishing is using port 80, same as IIS, both works together i think. I have to paste something on MYSQL folder?
no you don't have to paste anything in the mysql folder you can leave that disabled

change the IIS port to something other than 80 and run your apache on the port 80 see if that works
B1Q is offline  
Old 08/13/2019, 14:36   #47
 
elite*gold: 0
Join Date: Nov 2011
Posts: 228
Received Thanks: 18
Hello mate

Quote:
Originally Posted by Devsome View Post
Use a linux Server for website, windows sucks.
MySQL must use port 3306? or my port 81

Quote:
Originally Posted by B1Q View Post
no you don't have to paste anything in the mysql folder you can leave that disabled

change the IIS port to something other than 80 and run your apache on the port 80 see if that works
IIS is using port 8080, but when i disable World web publishing (who use port 80), IIS wont run, so idk if they works toguether. My question is IIS must be enabled or disabled to run wampserver?

SOLVED, IT WAS A PROBLEM WITH APACHE PORTS.
ThievesUTD is offline  
Old 09/13/2019, 03:27   #48
 
Raymond*'s Avatar
 
elite*gold: 388
Join Date: Aug 2017
Posts: 164
Received Thanks: 109
good bro
Raymond* is offline  
Old 04/21/2020, 11:36   #49
 
Manuel1014's Avatar
 
elite*gold: 0
Join Date: May 2009
Posts: 6
Received Thanks: 4
First of all , thank you for the release , Please any1 HALP me with this website , the pages like white , i can see the website but when i click anything is white...nothing there i mean,the website is xD
Manuel1014 is offline  
Old 04/22/2020, 06:54   #50
 
elite*gold: 0
Join Date: Feb 2014
Posts: 75
Received Thanks: 14
thanks for site
but i have problem
Quote:
Notice: Undefined index: Time in C:\Program Files (x86)\Zend\Apache24\htdocs\lastuniques\config.php on line 152
i fixed this but where FTW in site ^^


i have problem

RulesGame is offline  
Old 04/22/2020, 22:54   #51
 
B1Q's Avatar
 
elite*gold: 350
Join Date: Aug 2015
Posts: 1,999
Received Thanks: 1,188


this is the better version with a better design and the timer things in it go use it

EDIT: Registration class that does not use email verification
Code:
<?php
if (Loggedin())
    die("loggedin");
$errors = array('message' => '', 'state' => 'error');
if (empty($_POST['username'])
    || empty($_POST['password'])
    || empty($_POST['password2'])
) {
    $errors['state'] = "error";
    $errors['message'] = "All Fields are Required!<br>";
}
if ($_allowSecretCode && empty($_POST['secretn'])) {
    $errors['state'] = "error";
    $errors['message'] = "Secret Code is Required!";
}
if ($_rrequireEmail && empty($_POST['email'])) {
    $errors['state'] = "error";
    $errors['message'] = "Email is Required!";
} else if (empty($errors['message'])) {
    /* POST data */
    $username = $_POST['username'];
    $password = $_POST['password'];
    $password2 = $_POST['password2'];
    $email = $_POST['email'] ?? "";
    $secret = $_POST['secretn'] ?? "";


    if (!alphanum($username))
        $errors['message'] .= "The Username field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password))
        $errors['message'] .= "The Password field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password2))
        $errors['message'] .= "The Password Confirm field may only contain alpha-numeric characters.<br>";
    if ($_allowSecretCode && !empty($secret) && !isnum($secret))
        $errors['message'] .= "The SecretCode field must contain only numbers.<br>";
    if ($_rrequireEmail && !filter_var($email, FILTER_VALIDATE_EMAIL))
        $errors['message'] .= "Incorrect email format";


    else if (empty($errors['message'])) {
        /* exists? */
        $userexist = _Count("select * from $array[3]..TB_User where StrUserID=:User", array(':User' => $username));
        $userawaitsverify = _Count("select * from $array[3]..TB_Unverified where Username=:User", array(':User' => $username));
        $emailexist = _Count("select * from $array[3]..TB_User where Email=:email", array(':email' => $email));
        $emailexistverify = _Count("select * from $array[3]..TB_Unverified where Email=:email", array(':email' => $email));
        if ($userexist > 0 || $userawaitsverify > 0)
            $errors['message'] .= "Username Already Exists!<br>";
        if ($emailexist > 0 || $emailexistverify > 0 && $_rrequireEmail)
            $errors['message'] .= "Email Already Exists!<br>";
        if ($_allowSecretCode && empty($secret))
            $errors['message'] .= "Secret Code Cannot be empty.!<br>";
        if ($password != $password2)
            $errors['message'] .= "Passwords Doesn't Match!";


        else if ($userexist <= 0 && $userawaitsverify <= 0 && $password == $password2
                    || $_rrequireEmail && $emailexist <= 0 && $emailexistverify <= 0) {
            $secretcol = $_allowSecretCode ? "," . $_secretCodeColumn : "";
            $secretval = $_allowSecretCode ? ",:secret" : "";
            $emailcol = $_rrequireEmail ? ",Email" : "";
            $emailval = $_rrequireEmail ? ",:email" : "";
            $userdata = array(':user' => $username, ':pass' => md5($password));
            if ($_allowSecretCode && !empty($secret))
                $userdata[':secret'] = $secret;
            if ($_rrequireEmail && !empty($email))
                $userdata[':email'] = $email;


            $ip = $_SERVER['REMOTE_ADDR'];
            $date = date("Y-m-d H:i:s");
            $userdata['ip'] = $ip;
            $userdata['date'] = $date;
            $userdata['verify'] = rand(5555, 99999999);
            $insertuser = query("insert into $array[3]..TB_User (StrUserID,Password $secretcol $emailcol) values (:user,:pass $secretval $emailval)", $userdata);

            //$query = "insert into $array[3]..TB_Unverified (Username,Password,RegIP,Date,VerificationCode $secretcol $emailcol) values (:user,:pass,:ip,:date,:verify $secretval $emailval)";
            $insertuser = query($query, $userdata);
            $emailSubject = "$serverName account verification";
            $emailContent = "Dear $username,<br>Please verify your $serverName account using the link below<br>
                             <a href='$serverURL?p=v&k=$userdata[verify]'>Verify</a>";
            //&& SendEmail($email, $emailSubject, $emailContent)
            if ($insertuser) {
                $errors['state'] = "success";
                $errors['message'] = "Your Account Was Successfully Created!";
            }
        }
    }
}

use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

function SendEmail($email, $subject, $content)
{
    global $replyEmail;
    global $serverEmail;
    global $serverName;
    global $smtpHost;
    global $smtpUser;
    global $smtpPass;
    global $smtpPort;
    require PATH . 'include/src/PHPMailer.php';
    require PATH . 'include/src/SMTP.php';


    $mail = new PHPMailer(true);                              // Passing `true` enables exceptions
    try {
        //Server settings
        //$mail->SMTPDebug = 2;                                 // Enable verbose debug output
        $mail->isSMTP();                                      // Set mailer to use SMTP
        $mail->Host = $smtpHost;  // Specify main and backup SMTP servers
        $mail->SMTPAuth = true;                               // Enable SMTP authentication
        $mail->Username = $smtpUser;                 // SMTP username
        $mail->Password = $smtpPass;                           // SMTP password
        $mail->SMTPSecure = 'tls';                            // Enable TLS encryption, `ssl` also accepted
        $mail->Port = $smtpPort;                                    // TCP port to connect to

        //Recipients
        $mail->setFrom($serverEmail, $serverName);
        $mail->addAddress($email);     // Add a recipient
        $mail->addReplyTo($replyEmail, $serverName);

        //Content
        $mail->isHTML(true);                                  // Set email format to HTML
        $mail->Subject = $subject;
        $mail->Body = $content;

        return $mail->send();
    } catch (Exception $e) {
        _log("mailLog.log", $e->getMessage());
        return false;
    }
}

echo json_encode($errors);
exit;
B1Q is offline  
Thanks
4 Users
Old 04/24/2020, 00:41   #52
 
elite*gold: 0
Join Date: Jun 2007
Posts: 34
Received Thanks: 1
show a design
Van2Lee is offline  
Old 04/26/2020, 00:16   #53
 
elite*gold: 0
Join Date: Feb 2014
Posts: 75
Received Thanks: 14
Quote:
Originally Posted by B1Q View Post


this is the better version with a better design and the timer things in it go use it

EDIT: Registration class that does not use email verification
Code:
<?php
if (Loggedin())
    die("loggedin");
$errors = array('message' => '', 'state' => 'error');
if (empty($_POST['username'])
    || empty($_POST['password'])
    || empty($_POST['password2'])
) {
    $errors['state'] = "error";
    $errors['message'] = "All Fields are Required!<br>";
}
if ($_allowSecretCode && empty($_POST['secretn'])) {
    $errors['state'] = "error";
    $errors['message'] = "Secret Code is Required!";
}
if ($_rrequireEmail && empty($_POST['email'])) {
    $errors['state'] = "error";
    $errors['message'] = "Email is Required!";
} else if (empty($errors['message'])) {
    /* POST data */
    $username = $_POST['username'];
    $password = $_POST['password'];
    $password2 = $_POST['password2'];
    $email = $_POST['email'] ?? "";
    $secret = $_POST['secretn'] ?? "";


    if (!alphanum($username))
        $errors['message'] .= "The Username field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password))
        $errors['message'] .= "The Password field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password2))
        $errors['message'] .= "The Password Confirm field may only contain alpha-numeric characters.<br>";
    if ($_allowSecretCode && !empty($secret) && !isnum($secret))
        $errors['message'] .= "The SecretCode field must contain only numbers.<br>";
    if ($_rrequireEmail && !filter_var($email, FILTER_VALIDATE_EMAIL))
        $errors['message'] .= "Incorrect email format";


    else if (empty($errors['message'])) {
        /* exists? */
        $userexist = _Count("select * from $array[3]..TB_User where StrUserID=:User", array(':User' => $username));
        $userawaitsverify = _Count("select * from $array[3]..TB_Unverified where Username=:User", array(':User' => $username));
        $emailexist = _Count("select * from $array[3]..TB_User where Email=:email", array(':email' => $email));
        $emailexistverify = _Count("select * from $array[3]..TB_Unverified where Email=:email", array(':email' => $email));
        if ($userexist > 0 || $userawaitsverify > 0)
            $errors['message'] .= "Username Already Exists!<br>";
        if ($emailexist > 0 || $emailexistverify > 0 && $_rrequireEmail)
            $errors['message'] .= "Email Already Exists!<br>";
        if ($_allowSecretCode && empty($secret))
            $errors['message'] .= "Secret Code Cannot be empty.!<br>";
        if ($password != $password2)
            $errors['message'] .= "Passwords Doesn't Match!";


        else if ($userexist <= 0 && $userawaitsverify <= 0 && $password == $password2
                    || $_rrequireEmail && $emailexist <= 0 && $emailexistverify <= 0) {
            $secretcol = $_allowSecretCode ? "," . $_secretCodeColumn : "";
            $secretval = $_allowSecretCode ? ",:secret" : "";
            $emailcol = $_rrequireEmail ? ",Email" : "";
            $emailval = $_rrequireEmail ? ",:email" : "";
            $userdata = array(':user' => $username, ':pass' => md5($password));
            if ($_allowSecretCode && !empty($secret))
                $userdata[':secret'] = $secret;
            if ($_rrequireEmail && !empty($email))
                $userdata[':email'] = $email;


            $ip = $_SERVER['REMOTE_ADDR'];
            $date = date("Y-m-d H:i:s");
            $userdata['ip'] = $ip;
            $userdata['date'] = $date;
            $userdata['verify'] = rand(5555, 99999999);
            $insertuser = query("insert into $array[3]..TB_User (StrUserID,Password $secretcol $emailcol) values (:user,:pass $secretval $emailval)", $userdata);

            //$query = "insert into $array[3]..TB_Unverified (Username,Password,RegIP,Date,VerificationCode $secretcol $emailcol) values (:user,:pass,:ip,:date,:verify $secretval $emailval)";
            $insertuser = query($query, $userdata);
            $emailSubject = "$serverName account verification";
            $emailContent = "Dear $username,<br>Please verify your $serverName account using the link below<br>
                             <a href='$serverURL?p=v&k=$userdata[verify]'>Verify</a>";
            //&& SendEmail($email, $emailSubject, $emailContent)
            if ($insertuser) {
                $errors['state'] = "success";
                $errors['message'] = "Your Account Was Successfully Created!";
            }
        }
    }
}

use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

function SendEmail($email, $subject, $content)
{
    global $replyEmail;
    global $serverEmail;
    global $serverName;
    global $smtpHost;
    global $smtpUser;
    global $smtpPass;
    global $smtpPort;
    require PATH . 'include/src/PHPMailer.php';
    require PATH . 'include/src/SMTP.php';


    $mail = new PHPMailer(true);                              // Passing `true` enables exceptions
    try {
        //Server settings
        //$mail->SMTPDebug = 2;                                 // Enable verbose debug output
        $mail->isSMTP();                                      // Set mailer to use SMTP
        $mail->Host = $smtpHost;  // Specify main and backup SMTP servers
        $mail->SMTPAuth = true;                               // Enable SMTP authentication
        $mail->Username = $smtpUser;                 // SMTP username
        $mail->Password = $smtpPass;                           // SMTP password
        $mail->SMTPSecure = 'tls';                            // Enable TLS encryption, `ssl` also accepted
        $mail->Port = $smtpPort;                                    // TCP port to connect to

        //Recipients
        $mail->setFrom($serverEmail, $serverName);
        $mail->addAddress($email);     // Add a recipient
        $mail->addReplyTo($replyEmail, $serverName);

        //Content
        $mail->isHTML(true);                                  // Set email format to HTML
        $mail->Subject = $subject;
        $mail->Body = $content;

        return $mail->send();
    } catch (Exception $e) {
        _log("mailLog.log", $e->getMessage());
        return false;
    }
}

echo json_encode($errors);
exit;
where i edit that ?

i can`t login and register

i can`t login and register

i can`t login and register
RulesGame is offline  
Old 09/23/2020, 11:40   #54
 
elite*gold: 0
Join Date: Apr 2015
Posts: 3
Received Thanks: 0
Help

Quote:
Originally Posted by B1Q View Post


this is the better version with a better design and the timer things in it go use it

EDIT: Registration class that does not use email verification
Code:
<?php
if (Loggedin())
    die("loggedin");
$errors = array('message' => '', 'state' => 'error');
if (empty($_POST['username'])
    || empty($_POST['password'])
    || empty($_POST['password2'])
) {
    $errors['state'] = "error";
    $errors['message'] = "All Fields are Required!<br>";
}
if ($_allowSecretCode && empty($_POST['secretn'])) {
    $errors['state'] = "error";
    $errors['message'] = "Secret Code is Required!";
}
if ($_rrequireEmail && empty($_POST['email'])) {
    $errors['state'] = "error";
    $errors['message'] = "Email is Required!";
} else if (empty($errors['message'])) {
    /* POST data */
    $username = $_POST['username'];
    $password = $_POST['password'];
    $password2 = $_POST['password2'];
    $email = $_POST['email'] ?? "";
    $secret = $_POST['secretn'] ?? "";


    if (!alphanum($username))
        $errors['message'] .= "The Username field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password))
        $errors['message'] .= "The Password field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password2))
        $errors['message'] .= "The Password Confirm field may only contain alpha-numeric characters.<br>";
    if ($_allowSecretCode && !empty($secret) && !isnum($secret))
        $errors['message'] .= "The SecretCode field must contain only numbers.<br>";
    if ($_rrequireEmail && !filter_var($email, FILTER_VALIDATE_EMAIL))
        $errors['message'] .= "Incorrect email format";


    else if (empty($errors['message'])) {
        /* exists? */
        $userexist = _Count("select * from $array[3]..TB_User where StrUserID=:User", array(':User' => $username));
        $userawaitsverify = _Count("select * from $array[3]..TB_Unverified where Username=:User", array(':User' => $username));
        $emailexist = _Count("select * from $array[3]..TB_User where Email=:email", array(':email' => $email));
        $emailexistverify = _Count("select * from $array[3]..TB_Unverified where Email=:email", array(':email' => $email));
        if ($userexist > 0 || $userawaitsverify > 0)
            $errors['message'] .= "Username Already Exists!<br>";
        if ($emailexist > 0 || $emailexistverify > 0 && $_rrequireEmail)
            $errors['message'] .= "Email Already Exists!<br>";
        if ($_allowSecretCode && empty($secret))
            $errors['message'] .= "Secret Code Cannot be empty.!<br>";
        if ($password != $password2)
            $errors['message'] .= "Passwords Doesn't Match!";


        else if ($userexist <= 0 && $userawaitsverify <= 0 && $password == $password2
                    || $_rrequireEmail && $emailexist <= 0 && $emailexistverify <= 0) {
            $secretcol = $_allowSecretCode ? "," . $_secretCodeColumn : "";
            $secretval = $_allowSecretCode ? ",:secret" : "";
            $emailcol = $_rrequireEmail ? ",Email" : "";
            $emailval = $_rrequireEmail ? ",:email" : "";
            $userdata = array(':user' => $username, ':pass' => md5($password));
            if ($_allowSecretCode && !empty($secret))
                $userdata[':secret'] = $secret;
            if ($_rrequireEmail && !empty($email))
                $userdata[':email'] = $email;


            $ip = $_SERVER['REMOTE_ADDR'];
            $date = date("Y-m-d H:i:s");
            $userdata['ip'] = $ip;
            $userdata['date'] = $date;
            $userdata['verify'] = rand(5555, 99999999);
            $insertuser = query("insert into $array[3]..TB_User (StrUserID,Password $secretcol $emailcol) values (:user,:pass $secretval $emailval)", $userdata);

            //$query = "insert into $array[3]..TB_Unverified (Username,Password,RegIP,Date,VerificationCode $secretcol $emailcol) values (:user,:pass,:ip,:date,:verify $secretval $emailval)";
            $insertuser = query($query, $userdata);
            $emailSubject = "$serverName account verification";
            $emailContent = "Dear $username,<br>Please verify your $serverName account using the link below<br>
                             <a href='$serverURL?p=v&k=$userdata[verify]'>Verify</a>";
            //&& SendEmail($email, $emailSubject, $emailContent)
            if ($insertuser) {
                $errors['state'] = "success";
                $errors['message'] = "Your Account Was Successfully Created!";
            }
        }
    }
}

use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

function SendEmail($email, $subject, $content)
{
    global $replyEmail;
    global $serverEmail;
    global $serverName;
    global $smtpHost;
    global $smtpUser;
    global $smtpPass;
    global $smtpPort;
    require PATH . 'include/src/PHPMailer.php';
    require PATH . 'include/src/SMTP.php';


    $mail = new PHPMailer(true);                              // Passing `true` enables exceptions
    try {
        //Server settings
        //$mail->SMTPDebug = 2;                                 // Enable verbose debug output
        $mail->isSMTP();                                      // Set mailer to use SMTP
        $mail->Host = $smtpHost;  // Specify main and backup SMTP servers
        $mail->SMTPAuth = true;                               // Enable SMTP authentication
        $mail->Username = $smtpUser;                 // SMTP username
        $mail->Password = $smtpPass;                           // SMTP password
        $mail->SMTPSecure = 'tls';                            // Enable TLS encryption, `ssl` also accepted
        $mail->Port = $smtpPort;                                    // TCP port to connect to

        //Recipients
        $mail->setFrom($serverEmail, $serverName);
        $mail->addAddress($email);     // Add a recipient
        $mail->addReplyTo($replyEmail, $serverName);

        //Content
        $mail->isHTML(true);                                  // Set email format to HTML
        $mail->Subject = $subject;
        $mail->Body = $content;

        return $mail->send();
    } catch (Exception $e) {
        _log("mailLog.log", $e->getMessage());
        return false;
    }
}

echo json_encode($errors);
exit;



Parse error: syntax error, unexpected '?' in C:\Program Files (x86)\Zend\Apache2\htdocs\test\include\sql.php on line 145
hetlarajax100 is offline  
Old 09/23/2020, 13:23   #55
dotCom
 
Devsome's Avatar
 
elite*gold: 9842
The Black Market: 107/0/0
Join Date: Mar 2009
Posts: 16,834
Received Thanks: 4,667
Quote:
Originally Posted by hetlarajax100 View Post
Parse error: syntax error, unexpected '?' in C:\Program Files (x86)\Zend\Apache2\htdocs\test\include\sql.php on line 145
Use newest PHP Version
Devsome is offline  
Old 09/17/2022, 07:30   #56
 
Hef3stO's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 16
Received Thanks: 5
Quote:
Originally Posted by B1Q View Post


this is the better version with a better design and the timer things in it go use it

EDIT: Registration class that does not use email verification
Code:
<?php
if (Loggedin())
    die("loggedin");
$errors = array('message' => '', 'state' => 'error');
if (empty($_POST['username'])
    || empty($_POST['password'])
    || empty($_POST['password2'])
) {
    $errors['state'] = "error";
    $errors['message'] = "All Fields are Required!<br>";
}
if ($_allowSecretCode && empty($_POST['secretn'])) {
    $errors['state'] = "error";
    $errors['message'] = "Secret Code is Required!";
}
if ($_rrequireEmail && empty($_POST['email'])) {
    $errors['state'] = "error";
    $errors['message'] = "Email is Required!";
} else if (empty($errors['message'])) {
    /* POST data */
    $username = $_POST['username'];
    $password = $_POST['password'];
    $password2 = $_POST['password2'];
    $email = $_POST['email'] ?? "";
    $secret = $_POST['secretn'] ?? "";


    if (!alphanum($username))
        $errors['message'] .= "The Username field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password))
        $errors['message'] .= "The Password field may only contain alpha-numeric characters.<br>";
    if (!alphanum($password2))
        $errors['message'] .= "The Password Confirm field may only contain alpha-numeric characters.<br>";
    if ($_allowSecretCode && !empty($secret) && !isnum($secret))
        $errors['message'] .= "The SecretCode field must contain only numbers.<br>";
    if ($_rrequireEmail && !filter_var($email, FILTER_VALIDATE_EMAIL))
        $errors['message'] .= "Incorrect email format";


    else if (empty($errors['message'])) {
        /* exists? */
        $userexist = _Count("select * from $array[3]..TB_User where StrUserID=:User", array(':User' => $username));
        $userawaitsverify = _Count("select * from $array[3]..TB_Unverified where Username=:User", array(':User' => $username));
        $emailexist = _Count("select * from $array[3]..TB_User where Email=:email", array(':email' => $email));
        $emailexistverify = _Count("select * from $array[3]..TB_Unverified where Email=:email", array(':email' => $email));
        if ($userexist > 0 || $userawaitsverify > 0)
            $errors['message'] .= "Username Already Exists!<br>";
        if ($emailexist > 0 || $emailexistverify > 0 && $_rrequireEmail)
            $errors['message'] .= "Email Already Exists!<br>";
        if ($_allowSecretCode && empty($secret))
            $errors['message'] .= "Secret Code Cannot be empty.!<br>";
        if ($password != $password2)
            $errors['message'] .= "Passwords Doesn't Match!";


        else if ($userexist <= 0 && $userawaitsverify <= 0 && $password == $password2
                    || $_rrequireEmail && $emailexist <= 0 && $emailexistverify <= 0) {
            $secretcol = $_allowSecretCode ? "," . $_secretCodeColumn : "";
            $secretval = $_allowSecretCode ? ",:secret" : "";
            $emailcol = $_rrequireEmail ? ",Email" : "";
            $emailval = $_rrequireEmail ? ",:email" : "";
            $userdata = array(':user' => $username, ':pass' => md5($password));
            if ($_allowSecretCode && !empty($secret))
                $userdata[':secret'] = $secret;
            if ($_rrequireEmail && !empty($email))
                $userdata[':email'] = $email;


            $ip = $_SERVER['REMOTE_ADDR'];
            $date = date("Y-m-d H:i:s");
            $userdata['ip'] = $ip;
            $userdata['date'] = $date;
            $userdata['verify'] = rand(5555, 99999999);
            $insertuser = query("insert into $array[3]..TB_User (StrUserID,Password $secretcol $emailcol) values (:user,:pass $secretval $emailval)", $userdata);

            //$query = "insert into $array[3]..TB_Unverified (Username,Password,RegIP,Date,VerificationCode $secretcol $emailcol) values (:user,:pass,:ip,:date,:verify $secretval $emailval)";
            $insertuser = query($query, $userdata);
            $emailSubject = "$serverName account verification";
            $emailContent = "Dear $username,<br>Please verify your $serverName account using the link below<br>
                             <a href='$serverURL?p=v&k=$userdata[verify]'>Verify</a>";
            //&& SendEmail($email, $emailSubject, $emailContent)
            if ($insertuser) {
                $errors['state'] = "success";
                $errors['message'] = "Your Account Was Successfully Created!";
            }
        }
    }
}

use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

function SendEmail($email, $subject, $content)
{
    global $replyEmail;
    global $serverEmail;
    global $serverName;
    global $smtpHost;
    global $smtpUser;
    global $smtpPass;
    global $smtpPort;
    require PATH . 'include/src/PHPMailer.php';
    require PATH . 'include/src/SMTP.php';


    $mail = new PHPMailer(true);                              // Passing `true` enables exceptions
    try {
        //Server settings
        //$mail->SMTPDebug = 2;                                 // Enable verbose debug output
        $mail->isSMTP();                                      // Set mailer to use SMTP
        $mail->Host = $smtpHost;  // Specify main and backup SMTP servers
        $mail->SMTPAuth = true;                               // Enable SMTP authentication
        $mail->Username = $smtpUser;                 // SMTP username
        $mail->Password = $smtpPass;                           // SMTP password
        $mail->SMTPSecure = 'tls';                            // Enable TLS encryption, `ssl` also accepted
        $mail->Port = $smtpPort;                                    // TCP port to connect to

        //Recipients
        $mail->setFrom($serverEmail, $serverName);
        $mail->addAddress($email);     // Add a recipient
        $mail->addReplyTo($replyEmail, $serverName);

        //Content
        $mail->isHTML(true);                                  // Set email format to HTML
        $mail->Subject = $subject;
        $mail->Body = $content;

        return $mail->send();
    } catch (Exception $e) {
        _log("mailLog.log", $e->getMessage());
        return false;
    }
}

echo json_encode($errors);
exit;
Hello, its me 2 years later xD

i have an issue, my register page doesn't work it show a fake successful msg when i create the acc but when i check the DB the account is not there

also i can't change password from the account panel either

im using apache2 in linux and php 7.4
Hef3stO is offline  
Old 11/03/2023, 16:35   #57
 
elite*gold: 0
Join Date: Feb 2019
Posts: 10
Received Thanks: 0
Thanks but not working for me
areemdee2019 is offline  
Reply


Similar Threads Similar Threads
SSN Online | Cap 70 | OldSchool | Achievement System | VeryOriginal | Low Rates
05/10/2018 - SRO PServer Advertising - 917 Replies
Links: Website: SSN Online (sorry) Download: SSN Online Facebook page: SSN Onlyn Discord: Join Now!



All times are GMT +1. The time now is 12:40.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.