Thanks for the help everyone. It is now fixed. They guy that originally
set it up used the //servername. I removed the // and it works fine, until
it got to the next error. :)
This is going to take a while. I'm sure I'll be back with more questions.
"Peter Westergaard" <[EMAIL PROTECTED]> wrote in message
Rick Taylor wrote:
I'm new to PHP and having issues. We have seperate servers for them. We
can use ODBC to test the connection and it works fine. However, when we
try to run the site we get a message of *** Error: Unable to Connect to
Database. Please Try Again Later. ***
We are using a custom app that we aren't getting a lot of assistance
with. The relevant lines in the app are:
define("DBHOST", "//database server name");
if(!$dbCon=mssql_connect(DBHOST,DBUSER,DBPASS)) $error = "Unable to
Connect to Database. Please Try Again Later.";
Can anyone assist a noob php user?
Thanks for removing any extraneous/irrelevant code. Nice, well-laid-out
The obvious follow-up-question presents itself, so forgive me for asking
if I'm underestimating, but you didn't mention whether or not you were
quoting it verbatim, or whether you had replaced your database host,
userid, and password from the code before you pasted it here.
Just in case it's the really obvious problem, you should be aware that you
are expected to fill in those lines as relevant to your MSSQL server.
For example, if the MSSQL serer was living on a server called "TORFOX001"
(or "//TORFOX001" in the MS local-network naming format), and you'd set it
up with a userid "zippy" with password "pinh34d", those lines should be
modified to read:
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php