Ok so, I'm using this reg page :
Alles anzeigen
And I'm using WAMP, I put my page on www
Do localhost and I try to go to the reg page,
I get that MSSQL Extension is not enabled in php.ini, i go to change it, and still gives the same problem.
How can I fix this thing of WAMP?
PHP-Quellcode
- <?php
- $MD5Code = "kikugalanet"; // Your Neuz MD5 Code
- $dbAddr = "127.0.0.1"; // Your MSSQL Host IP
- $dbName = "ACCOUNT_DBF"; // Your Account Database
- $dbUser = "sa"; // Your Database user
- $dbPass = ""; // Your Database User password
- if(!extension_loaded("mssql")) {
- echo "The MSSQL extension is not enabled on your PHP. Enable it on your php.ini and try again.";
- exit();
- }
- ?>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en">
- <head>
- <title>Fly For Fun :: Official Files Simple Register Page</title>
- </head>
- <body>
- <?php
- function cleanFormData($data) {
- $data = @strtolower($data);
- $data = @trim($data);
- $data = @htmlentities($data);
- $data = @strip_tags($data);
- return $data;
- }
- if(isset($_POST['regacc'])) {
- // Form Data
- $usrLogin = cleanFormData($_POST['user']); // Username
- $usrPassNoMD5 = cleanFormData($_POST['pass']); // Password non-encrypted
- if($usrLogin = "" || empty($usrLogin) || $usrPassNoMD5 = "" || empty($usrPassNoMD5)) {
- echo "You left blank fields!";
- exit();
- }
- $dbLink = @mssql_connect($dbAddr, $dbUser, $dbPass);
- if(!$dbLink) {
- echo "Failed on processing your register form.<br />Reason: Cannot connect to SQL Server<br />Try to refresh the page or try again later.<br />We apologize for any inconvenience.";
- @mssql_close($dbLink);
- exit();
- }
- @mssql_select_db($dbName, $dbLink);
- $checkUsrQ = @mssql_query("SELECT account FROM ACCOUNT_TBL WHERE account='".$usrLogin."'");
- $checkUsr = @mssql_num_rows($checkUsrQ);
- if($checkUsr > 0) {
- echo "This username is already been used by another player.";
- @mssql_free_result($checkUsrQ);
- @mssql_close($dbLink);
- exit();
- } else {
- @mssql_free_result($checkUsrQ);
- @mssql_close($dbLink);
- $usrPass = md5($MD5Code . $usrPassNoMD5);
- $storedProc = @mssql_init("createaccount", $dbLink);
- $usrAccParameter = @mssql_bind($storedProc, '@account', $usrLogin, SQLVARCHAR, false, false, 15);
- $usrPwdParameter = @mssql_bind($storedProc, '@password', $usrPass, SQLVARCHAR, false, false, 32);
- $addNewUsr = @mssql_execute($storedProc);
- if(!$addNewUsr) {
- echo "Failed on processing your register form.<br />Try to refresh the page or try again later.<br />We apologize for any inconvenience.";
- } else {
- echo "Your account has been created sucessfully!<br />Your login: <b>".$usrLogin."</b> - Your Pass: ****<br />Enjoy playing on our servers!";
- }
- @mssql_free_statement($addNewUsr);
- @mssql_close($dbLink);
- }
- }
- ?>
- <form method="post" action="<?php echo $_SERVER['PHP_SELF'];?>">
- Username: <input type="text" name="user" size="15" maxlenght="15" /><br />
- Password: <input type="password" name="pass" size="15" /><br />
- Name: <input type
- <input type="submit" name="regacc" />
- </form>
- </body>
- </html>
And I'm using WAMP, I put my page on www
Do localhost and I try to go to the reg page,
I get that MSSQL Extension is not enabled in php.ini, i go to change it, and still gives the same problem.
How can I fix this thing of WAMP?