I am trying to recode a web site I have from ASP to PHP. Firstly i want to get a connection to the underlying SQL database.
When executing the code below in a php script i get a message in the browser "No input file specified". I found a few topics relating to the --enable discard path etc etc but this only seems to be based on Linux systems?
<?php
$myServer = "localhost";
$myUser = "sa";
$myPass = "";
$myDB = "ooh_webcontent";
$s = @mssql_connect($myServer, $myUser, $myPass)
or die("Couldn't connect to SQL Server on $myServer");
$d = @mssql_select_db($myDB, $s)
or die("Couldn't open database $myDB");
?>
Please can someone help?
PHP on win32 with IIS and MSSQL 2000
Moderator: General Moderators
-
ABoutAGirl
- Forum Newbie
- Posts: 1
- Joined: Fri Jan 10, 2003 8:23 am
Did you enable "mssql.so" or "mssql.dll"
May be you didn't ^^
- caseymanus
- Forum Commoner
- Posts: 34
- Joined: Wed Nov 20, 2002 10:32 pm
- Contact:
... or, you could try using the PEAR DB API for accessing mssql. From what I understand, the version of PEAR packaged with PHP v4.3 is considered stable on unix platforms, and in final beta stages for win32 and Darwin platforms. Give it a shot and see if it works.
here is the url to the PEAR DB API documentation:
http://pear.php.net/manual/en/core.db.php
Hope this helps
here is the url to the PEAR DB API documentation:
http://pear.php.net/manual/en/core.db.php
Hope this helps
Thanks for all your help
I have managed to fix the problem mainly by fluke. I am now able to use the mssql function without problem. It seems to work correctly on sql2k.
Cheers,
Static
Cheers,
Static