|  | Posted by Kevin Raleigh on 05/28/07 22:03 
I resolved the PHP warnings but now I have what seems to be quite a problemI think I messed up because when I tryed to connect to the
 database I have this error using this code:
 
 <?php
 $connection = mysql_connect("localhost", "raleigh", "1111") or die
 ("Couldn't connect to the server.");
 $db = mysql_select_db("secretDB", $connection) or die ("couldn't select
 database.");
 ?>
 
 Couldn't connect to the server.PHP Warning: mysql_connect()
 [function.mysql-connect]: Access denied for user 'raleigh'@'localhost'
 (using password: YES) in C:\Inetpub\wwwroot\phpBasics4.0\hs~connecting to a
 mysql database.php on line 2
 
 Can anyone advise
 
 Kevin
 
 "C." <colin.mckinnon@gmail.com> wrote in message
 news:1180306715.941127.89880@q66g2000hsg.googlegroups.com...
 > On 27 May, 05:11, "Kevin Raleigh" <krale...@sbcglobal.net> wrote:
 > > I have this DB connection code from the book
 > >
 > <snip irrelevant crud>
 > >
 > > When I run it I get the following errors
 > >
 > > CGI Error
 > > The specified CGI application misbehaved by not returning a complete set
 of
 > > HTTP headers. The headers it did return are:
 > >
 > > PHP Warning:  PHP Startup: Unable to load dynamic library 'C:\Program
 > > Files\PHP\ext\php_exif.dll' - The specified module could not be found.
 > >  in Unknown on line 0
 > > PHP Warning:  Module 'mysql' already loaded in Unknown on line 0
 > > PHP Warning:  PHP Startup: Unable to load dynamic library 'C:\Program
 > > Files\PHP\ext\php_oci8.dll' - The specified module could not be found.
 > >  in Unknown on line 0
 > <snip repeated errors>
 >
 > I suspect that you're probably not using must of the stuff PHP is
 > trying to link at runtime.
 >
 > 1) RTFM on how to configure PHP
 >
 > 2) From the command line run php with a -i flag to find out what it is
 > looking for its ini file. If there's not one there, then copy over the
 > one which came with your distribution.
 >
 > 3) Now edit it with a TEXT EDITOR (like notepad.exe)
 >
 > 4) repeat step 1
 >
 > 5) check the path to the extensions is set correctly
 >
 > 6) check what extension dlls you already have
 >
 > 7) comment out any extensions in the ini file which you don't need
 >
 > 8) restart your webserver
 >
 > 9) test
 >
 > Lather, rinse & repeat.
 >
 > C.
 >
  Navigation: [Reply to this message] |