Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[RELEASE] Simple C9 register page, Translated to EN

Custom Title Activated
Loyal Member
Joined
Aug 23, 2010
Messages
1,529
Reaction score
403
originally shared by xlmansox
i only translated to English

you need to have these enabled in your php.ini


download link:

Thanks for share i have error... i am using xampp and i get error, i have already this extension;

extension=php_sqlsrv_52_ts_vc6.dll
extension=php_pdo_sqlsrv_52_ts_vc6.dll
 
Experienced Elementalist
Joined
Sep 13, 2014
Messages
232
Reaction score
85
much more easy code. but not recommend to use it (about security).

Code:
<?php
session_start();
$mssql_host    =    "127.0.0.1,1433";
$mssql_user    =    "c9";
$mssql_pass    =    "Tlskdls";
$mssql_db    =    "C9Unity";
$ip = $_SERVER['REMOTE_ADDR'];


function cl($text)
{
    $a = str_replace("'","/",$text);
    return $a;
}


function popup($text)
{
    echo "<script>alert('".$text."');</script>";
}


include_once $_SERVER['DOCUMENT_ROOT'] . '/securimage/securimage.php';


$securimage = new Securimage();


mssql_connect($mssql_host,$mssql_user,$mssql_pass) or die("Cannot connect to SQL Server");
mssql_select_db($mssql_db) or die("Cannot selected database.");


if($_POST['submit'])
{
    // Check User
    $chk_user = mssql_query("SELECT cAccId FROM Auth.TblAccount WHERE cAccId = '".cl($_POST['account'])."'");
    $chk = mssql_fetch_array($chk_user);
    if(trim($_POST['account']) == "" || $_POST['password'] == "" || $_POST['repass'] == "" || $_POST['captcha_code'] == "")
    {
        popup("Please fill all field.");
    }
    else if(trim($_POST['account']) == $chk['cAccId'])
    {
        popup("Account name is already used.");
    }
    else if($_POST['password'] != $_POST['repass'])
    {
        popup("Password is not match");
    }
    else if ($securimage->check($_POST['captcha_code']) == false)
    {
        popup("Security code wrong.");
    }
    else
    {
        $username = cl($_POST['account']);
        $password = cl($_POST['repass']);
        $auth = (int)1;
        $stmt = mssql_init('Admin.UspAddAccount');
        mssql_bind($stmt, '@pAccId', $username, SQLVARCHAR, false, false, 32);
        mssql_bind($stmt, '@pPassword', $password, SQLVARCHAR, false, false, 32);
        mssql_bind($stmt, '@pAuthLevel', $auth, SQLVARCHAR, false, false, 32);
        mssql_bind($stmt, '@pIpAddr', $ip, SQLVARCHAR, false, false, 32);
        mssql_execute($stmt) or die ("<strong>Error occurred while executing the statement.</strong>");
        mssql_free_statement($stmt);
        popup("Welcome ".$username.". Enjoy the game.");
    }
}


?>
<form name="register" method="post" action="">
  <table width="500" align="center">
    <tr>
      <td align="right">Account Name :</td>
      <td><label for="account"></label>
      <input type="text" name="account" id="account" autocomplete="off"></td>
    </tr>
    <tr>
      <td align="right">Password :</td>
      <td><label for="password"></label>
      <input type="password" name="password" id="password"></td>
    </tr>
    <tr>
      <td align="right">Re-Password :</td>
      <td><label for="repass"></label>
      <input type="password" name="repass" id="repass"></td>
    </tr>
    <tr>
      <td align="right" valign="top">Security :</td>
      <td><img src="/securimage/securimage_show.php" alt="CAPTCHA Image" width="148" height="49" id="captcha" /><br><input type="text" name="captcha_code" autocomplete="off" size="10" maxlength="6" />
<a href="#" onclick="document.getElementById('captcha').src = '/securimage/securimage_show.php?' + Math.random(); return false">[ Different Image ]</a></td>
    </tr>
    <tr>
      <td> </td>
      <td><input type="submit" name="submit" id="submit" value="Register"></td>
    </tr>
  </table>
</form>


FULL :
 
Put Community First
Loyal Member
Joined
Oct 2, 2014
Messages
1,112
Reaction score
832
Thanks for share i have error... i am using xampp and i get error, i have already this extension;

extension=php_sqlsrv_52_ts_vc6.dll
extension=php_pdo_sqlsrv_52_ts_vc6.dll

Make sure your XAMPP installation is using the thread-safe settings, otherwise you need the nts versions of those .dll files, not the ts. You can check this using the phpinfo() page. Also make sure you keep the .dll files in the correct folder in the XAMPP installation folder (xampp\php\ext), ;).

In future, please make Help posts in the Help section, further Help posts in the wrong section will be deleted, :).
 
Junior Spellweaver
Joined
Aug 15, 2009
Messages
156
Reaction score
20
DESING REGISTER WEBZEN
Xoo0ie - [RELEASE] Simple C9 register page, Translated to EN - RaGEZONE Forums


Download here!
 

Attachments

You must be registered for see attachments list
Newbie Spellweaver
Joined
Dec 24, 2011
Messages
56
Reaction score
9
DESING REGISTER WEBZEN
Xoo0ie - [RELEASE] Simple C9 register page, Translated to EN - RaGEZONE Forums


Download here!

congratulations.
mssql not know much about, but I put in the field "$ip = $_SERVER['REMOTE_ADDR'];" ? What is it REMOTE_ADDR ?
 

Attachments

You must be registered for see attachments list
Junior Spellweaver
Joined
Oct 27, 2015
Messages
164
Reaction score
33
hey i vps use ...what wrong ?
Fatal error: Call to undefined function mssql_connect() in C:\Program Files\VertrigoServ\www\index.php on line 24

 
Back
Top