Problem with register

10/15/2011 16:16 smokevl#1
Hello i tryied to make register on server but i got this

Fatal error: Call to undefined function mssql_connect() in C:\xampp\htdocs\processor.php on line 10



Sorry for new post but old one are closeed .
10/15/2011 16:33 viper4513#2
look in the "processor.php" file in your xampp folder, specifically at line 10.

Seems to be an error around there. Check the reg script from Abrasive here, his thread has alot of answers on how to set up the script properly. Including a full guide by Castor.
10/15/2011 17:15 smokevl#3
i check script from Abrasive but now i got this

You must have the php_mssql library for Apache installed and enabled to connect to an MSSQL database. Uncomment the line that says extension=php_mssql.dll in your php.ini (XAMPP/WAMP only). This requires a restart of the Apache service to take effect.

Im using XAMPP
10/15/2011 17:24 RebeccaBlack#4
Fatal error: Call to undefined function mssql_connect() - You're missing the MSSQL functions.

Solution? Use ODBC, or SQLSrv, or get a version of PHP with MSSQL functions not disabled.
10/15/2011 18:40 smokevl#5
why never smothing can work fine for my now i got new error

Please type this in the text box below to prove you are human
Fatal error: Call to undefined function recaptcha_get_html() in C:\xampp\htdocs\register.view.php on line 31
10/15/2011 22:54 JohnHeatz#6
Quote:
Originally Posted by smokevl View Post
i check script from Abrasive but now i got this

You must have the php_mssql library for Apache installed and enabled to connect to an MSSQL database. Uncomment the line that says extension=php_mssql.dll in your php.ini (XAMPP/WAMP only). This requires a restart of the Apache service to take effect.

Im using XAMPP
You didn't uncomment (delete the ; in front of the lines) for the php_mssql.dll and/or extension=php_pdo_mssql.dll
02/24/2012 18:57 arshad2203#7
Fatal error: Call to undefined function mssql_connect() in C:\xampp\htdocs\Register\processor.php on line 7


and my processor.php file is like this..



<?php

$ip = $_SERVER['REMOTE_ADDR'];
$login = trim($_POST['login']);
$pass = trim($_POST['pass']);
$repass = trim($_POST['passp']);

// Connection with MSSQL server
$conn=mssql_connect('127.0.0.1', $ADMIN_NAME, $ADMIN_PASS);
$db = mssql_select_db('PS_UserData',$conn) or die("Connection error!");

$res = mssql_query("SELECT UserID FROM PS_UserData.dbo.Users_Master WHERE (UserID) = ('$login')");
if (mssql_num_rows($res))
{
echo "Login already exist.";
}
else
{
if ($pass != $repass)
{
echo 'Passwords mismatch.';
}
else
{
$query = "INSERT INTO PS_UserData.dbo.Users_Master (UserID, Pw, JoinDate, Admin, AdminLevel, UseQueue, Status, Leave, LeaveDate, UserType, UserIp, ModiIp, ModiDate, Point, Enpassword, Birth) VALUES ('$login', '$pass', GETDATE(), 0, 0,'',0,'', DATEADD(year, +10, GETDATE()),'A','$ip',NULL,NULL,1000000,NULL,NULL)" ;
$rresult = mssql_query($query) or die("Inster Error.");
{
echo "The account is created successfully.<br />You gained 1kk of Shaiya Points.<br /><br /><b>Login:</b> $login<br><b>Password:</b> $pass";
}
}

}


?>




what is error in line 7 ??
Can u write me a correct line pls??
02/25/2012 03:57 RebeccaBlack#8
First, DO NOT USE THAT REGISTER FILE! It's open to SQL Injection and will just cause problems for you.
Second, It is likely MSSQL functions aren't loaded into your version of PHP, there is an ODBC version of abrasive's secure register that should work for you. Check my signature for "ODBC Based PHP Scripts" and click the link.