|
Posted by Jerry Stuckle on 09/26/05 21:15
Bruce A. Julseth wrote:
> I do my development on a local machine with "localhost" as my mysql server.
> And, of course, I have different server when in production. So that I don't
> have to modify my code when I promote, I first connect to my production
> server. If that fails, I connect to my local server. Is this the best way,
> or is there a better way? Is there a way to detect which MySQL server is
> currently available to me?
>
> Thanks...
>
>
>
>
>
I just keep a configuration file in a directory below Apache root
directory so it can't be accessed from the web. The file contains
things like system names, user id's and passwords. I just include this
file to access the info.
The file is different on different systems, but it resides in the same
location relative to $_SERVER['DOCUMENT_ROOT'].
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
[Back to original message]
|