Best practice regarding MySQL username/pw in script file??



So I'm a relative noob with PHP/MySQL. Here's my question -- seems
pretty questionable from a security standpoint to have the MySQL
connection usernames/pw's embeded in PHP scripts all over a site. Is
there a better practice? Would something like this in every page be
better:

include ("../passwordprotected/SinglefilewithPHPlogininfo.php"); ?>
Database login info is still sitting in that file in clear text, but
seems better than multiple clear-text copies all over a site. Are
there better methods?

Thanks,

Chuck

.



Relevant Pages

  • Re: VFP8 & MySQL
    ... > VFP functions like NVL to a MySQL one, definitely it made the switch very ... > About your connection problem, I have mine setup as default for 100 ... As for the server, we left it ... The server crashed and corrupted the database. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Does apache stop a script mid execution ?
    ... If the user calls a time consuming script and then stops or refreshes ... How does it relate to e.g. a script performing a large mysql query? ... 2.b) how the connection is set up. ... the server stops the script execution. ...
    (comp.lang.php)
  • MySQL on Win 98
    ... I'm just getting into MySQL and I'm trying to learn about it at home. ... and created a DSN connection for it. ... User: root ... ODBC Data Source Administrator and get a "success" result. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: VFP8 & MySQL
    ... Main Location and 3 branches (these are remotely accessing MySQL at the main ... About your connection problem, I have mine setup as default for 100 ... As for the server, we left it alone. ... The server crashed and corrupted the database. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Java and MySql program example ?
    ... > I am trying to learn Java and need an example program with MySql ... > MySql database. ... Database connection established ...
    (comp.lang.java.programmer)