Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Enabling the MSSQL extention

Status
Not open for further replies.

irbk

MIS
Oct 20, 2004
578
US
Trying to get my IIS 6 web server to run PHP with the MSSQL extentions. I'v got PHP installed (version 5.1.4) and will display the phpinfo() page. However, I can not seem to get the MSSQL commands to work.
1. I've enabled the "extension=php_mssql.dll" in php.ini
2. I've copied the "php_mssql.dll" to win\sys32
3. I've copied the "ntwdblib.dll" from the database server to the IIS/PHP server
4. I've restarted the web services SEVERAL times.

However when ever any database commands are on a page, I just get a blank page, no error messages, nothing.

Any ideas to get this working?

Thanks.
 
is mssql configured to allow tcp/ip connections?
 
I believe it is. Suggestions on an easy way to test?
 
CORRECTION
In the phpinfo command I DO see the mssql as being enabled. However, when trying to connect with
Code:
define ('DB_SERVER', '<server>');
define ('DB_USER', '<user>');
define ('DB_PASSWORD', '<password>');
define ('DB_NAME', '<database>');
// Make the connection and then select the database.
$dbc = mssql_connect (DB_SERVER, DB_USER, DB_PASSWORD)
	or die ('Could not connect to MSSQL: ' . mssql_error());
@mssql_select_db (DB_NAME)
	or die ('Could not select the database: ' . mssql_error());
I get no connection OR error, the page is just blank.
 
Figured out part of the issue. "display_errors" in the php.ini file was set to "Off". I turned it "On" and now I'm at least getting errors back. Now I just have to figure out why my login is failing.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top