here is an overview of what we have setup.
I am a scripting newb...
Windows 2003 web server with php installed and appears to be working with a vairied amount of php speciifc scripts that work fine.
Windows 2003 with SQL 2005 database server. Databases can be accessed thru 100+ machines perfectly with the sql client tools.
Now all im trying to do is connect to the database server and post whatever info is in the table using php.
here is my coding:
<?
$server="tech-db,1433";
$username="php25";
$password="tech214";
$sqlconnect=mssql_connect($server, $username, $password);
$sqldb=mssql_select_db("php25",$sqlconnect);
$sqlquery="SELECT title FROM book;";
$results= mssql_query($sqlquery);
while ($row=mssql_fetch_array($results)){
echo $row['Book']."<br>\n";}
mssql_close($sqlconnect);
?>
I keep gettign the error message:
Fatal error: Call to undefined function mssql_connect() in D:\web\cpt214-25\test.php on line 5
Now if im understanding this right php does not understand the command "mssql_connect".
Did I do something incorrect when installing php on the windows 2003 webserver? If so what do I need to do to correct it. I have read and done a couple things to try and figure this out but am at a loss.
I have installed the sql client tools on the webserver, edited the php.ini file and uncommented extension=php_mssql.dll in the Dynamic Extensions area. I have added to the path on the server both where php is installed and the ext directory within it. I have also enablee about everything I can network wise on the sql server, named pipes, etc. Nothing seems to be working for this. I also cannot find many resources for mssql connection strings or troubleshooting, mostly just mysql stuff.
I am tryign to get this working for a teacher and neither of us understand what is going on here. Any help would be appreciated. Any info that you may need, please just ask. These servers are completely internal so there is no way to give access to them. I setup the servers so Im trying to double check to make sure things are correct.
[Mod Edit - bpat1434] Added
tags.