Register for your free account! | Forgot your password?

You last visited: Today at 09:35

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

Advertisement



please help me !

Discussion on please help me ! within the Dekaron Private Server forum part of the Dekaron category.

Reply
 
Old   #1
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
please help me !

this error



Code:
$mssql = array( 
        'host' => "192.168.1.3", 
        'user' => "sa", 
        'pass' => "123456" 
    ); 
     
echo "<center>Player Online List<br><br>"; 
echo "<table border='1'> 
    <tr> 
        <td align='center'>Character Name</td> 
        <td align='center'>Level</td> 
        <td align='center'>Map</td> 
        <td align='center'>Login</td> 

    </tr>"; 

$con = mssql_connect($mssql['host'],$mssql['user'],$mssql['pass']); 

$result1 = mssql_query("SELECT user_no FROM account.dbo.USER_PROFILE WHERE login_flag = '1100'",$con); 


while($row1 = mssql_fetch_row($result1)) { 
     
    $result2 = mssql_query("SELECT character_name,wLevel,wMapIndex,login_time FROM character.dbo.user_character WHERE user_no = '".$row1[0]."' ORDER by login_time DESC",$con); 
    $row2 = mssql_fetch_row($result2); 

        echo "<tr> 
            <td align='left'>".$row2[0]."</td> 
            <td align='center'>".$row2[1]."</td> 
            <td align='center'>".$row2[2]."</td> 
            <td align='center'>".$row2[3]."</td> 

        </tr>"; 

} 
echo "</table></center>"; 
?>
insteadof is offline  
Old 03/25/2011, 16:35   #2
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
up, help me pls , I want it
insteadof is offline  
Old 03/25/2011, 16:49   #3
 
elite*gold: 0
Join Date: May 2008
Posts: 509
Received Thanks: 1,246
Try removing $con from this line. Since you already have a link opened, theres no need to call it. Also make sure you have the php_mssql.dll extension enabled.
Code:
$result1 = mssql_query("SELECT user_no FROM account.dbo.USER_PROFILE WHERE login_flag = '1100'",$con);
=Warmonger= is offline  
Thanks
1 User
Old 03/26/2011, 01:49   #4
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
Quote:
Originally Posted by Warmonger1337 View Post
Try removing $con from this line. Since you already have a link opened, theres no need to call it. Also make sure you have the php_mssql.dll extension enabled.
Code:
$result1 = mssql_query("SELECT user_no FROM account.dbo.USER_PROFILE WHERE login_flag = '1100'",$con);
after a change , I get a new error
Code:
Parse error: syntax error, unexpected ')' in C:\Program Files\VertrigoServ\www\newreg\Player_Online_List_php.php on line 21
I can find it anywhere (php_mssql.dll)
insteadof is offline  
Old 03/26/2011, 02:17   #5
 
Decima's Avatar
 
elite*gold: 0
Join Date: Aug 2009
Posts: 1,297
Received Thanks: 928
first of all, warmonger, as usual, is incorrect, for the mssql u do need the $con, otherwise it wont connect to the DB

second, 'php_mssql.dll' can be found in a line in the httpd.conf file in ur apache folder, u need to uncomment that in order for it to load mssql extensions, be sure u save and restart the apache server b4 u try again.

usually i am against spoonfeeding the noobs, but the only thing worse then spoonfeeding them, is giving them bad info . . .

and u need to learn how ur apache server works, and u need to learn php otherwise your server willl be a miserable failure, they are both required to successfully run and admin a server.
Decima is offline  
Old 03/26/2011, 02:35   #6
 
҉ THT ҉'s Avatar
 
elite*gold: 0
Join Date: Jul 2009
Posts: 912
Received Thanks: 250
If you are using XAMPP
Open with notepad: 'xampp/php/php.ini'.
Go to line 617 OR find ';extension=php_mssql.dll'.

Replace line: ';extension=php_mssql.dll' with 'extension=php_mssql.dll'
OR delete ';' == ;extension=php_mssql.dll
҉ THT ҉ is offline  
Thanks
1 User
Old 03/26/2011, 02:38   #7
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
I use code by Janvier123
I only use the new reg code, code view online pen do not work

download all from
Please help me make it work

I use Vertrigo it ok ?
insteadof is offline  
Old 03/26/2011, 02:49   #8
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
Quote:
Originally Posted by ҉ THT ҉ View Post
If you are using XAMPP
Open with notepad: 'xampp/php/php.ini'.
Go to line 617 OR find ';extension=php_mssql.dll'.

Replace line: ';extension=php_mssql.dll' with 'extension=php_mssql.dll'
OR delete ';' == ;extension=php_mssql.dll
I tried doing so with Vertrigo, but not
insteadof is offline  
Old 03/26/2011, 18:30   #9
 
elite*gold: 0
Join Date: May 2008
Posts: 509
Received Thanks: 1,246
Quote:
Originally Posted by Decima View Post
first of all, warmonger, as usual, is incorrect, for the mssql u do need the $con, otherwise it wont connect to the DB

second, 'php_mssql.dll' can be found in a line in the httpd.conf file in ur apache folder, u need to uncomment that in order for it to load mssql extensions, be sure u save and restart the apache server b4 u try again.

usually i am against spoonfeeding the noobs, but the only thing worse then spoonfeeding them, is giving them bad info . . .

and u need to learn how ur apache server works, and u need to learn php otherwise your server willl be a miserable failure, they are both required to successfully run and admin a server.
Wrong kid, I can sit here and spoon feed you all day. But sitting back and watching you realize how wrong you are from the start should be a learning experience all its own. You do NOT need to call a active connection, if one is already open, php will automatically default and use the last one active. So really the $con itself is just a waste of text. Secondly the php extensions are enabled through php.ini configuration file, not through the web servers config file (kinda makes sense php extensions enabled in php configurations?). And who uses slow *** insecure apache anymore? Time for you people to catch up with the times.
=Warmonger= is offline  
Old 03/26/2011, 19:46   #10
 
Decima's Avatar
 
elite*gold: 0
Join Date: Aug 2009
Posts: 1,297
Received Thanks: 928
hmm, it is php.ini, that u are right about, dunno wtf i was thinking giving out httpd.conf :O
so, toche' ill give you that one

but i just tested ur theory on $con 3 times in a row and get an error everytime

but hey, i guess it knows how 1337 u are . . . .
Decima is offline  
Old 03/27/2011, 23:22   #11
 
҉ THT ҉'s Avatar
 
elite*gold: 0
Join Date: Jul 2009
Posts: 912
Received Thanks: 250
did you restart your apache server for sure?
҉ THT ҉ is offline  
Old 03/28/2011, 11:52   #12
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
Quote:
Originally Posted by ҉ THT ҉ View Post
did you restart your apache server for sure?
I use xampp and do as you say, but it does not work
insteadof is offline  
Old 03/28/2011, 13:27   #13
 
҉ THT ҉'s Avatar
 
elite*gold: 0
Join Date: Jul 2009
Posts: 912
Received Thanks: 250
did you restart xampp?
҉ THT ҉ is offline  
Old 03/29/2011, 04:06   #14
 
insteadof's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 114
Received Thanks: 10
I do not find extension = php_mssql.dll' in php.ini of xampp why?
insteadof is offline  
Old 03/29/2011, 05:39   #15
 
Decima's Avatar
 
elite*gold: 0
Join Date: Aug 2009
Posts: 1,297
Received Thanks: 928
its going to be around line number 965 depending on ur version, it will look like this:
Code:
; Windows Extensions
; Note that ODBC support is built in, so no dll is needed for it.
; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
; extension folders as well as the separate PECL DLL download (PHP 5).
; Be sure to appropriately set the extension_dir directive.

extension=php_bz2.dll
;extension=php_curl.dll
;extension=php_dba.dll
extension=php_mbstring.dll
extension=php_exif.dll
;extension=php_fileinfo.dll
extension=php_gd2.dll
extension=php_gettext.dll
;extension=php_gmp.dll
extension=php_imap.dll
;extension=php_interbase.dll
;extension=php_intl.dll
;extension=php_ldap.dll
extension=php_mcrypt.dll
;extension=php_mssql.dll
;extension=php_mysql_mysqlnd.dll
extension=php_mysql_libmysql.dll
;extension=php_mysqli_mysqlnd.dll
extension=php_mysqli_libmysql.dll
u can find it in xampp/php/php.ini

just take the comment out so it looks like so:
Code:
; Windows Extensions
; Note that ODBC support is built in, so no dll is needed for it.
; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
; extension folders as well as the separate PECL DLL download (PHP 5).
; Be sure to appropriately set the extension_dir directive.

extension=php_bz2.dll
;extension=php_curl.dll
;extension=php_dba.dll
extension=php_mbstring.dll
extension=php_exif.dll
;extension=php_fileinfo.dll
extension=php_gd2.dll
extension=php_gettext.dll
;extension=php_gmp.dll
extension=php_imap.dll
;extension=php_interbase.dll
;extension=php_intl.dll
;extension=php_ldap.dll
extension=php_mcrypt.dll
extension=php_mssql.dll
;extension=php_mysql_mysqlnd.dll
extension=php_mysql_libmysql.dll
;extension=php_mysqli_mysqlnd.dll
extension=php_mysqli_libmysql.dll
Decima is offline  
Thanks
1 User
Reply




All times are GMT +1. The time now is 09:36.


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.