Re: Question on Database

From: Date: Wed, 10 Oct 2001 01:37:36 +0000
Subject: Re: Question on Database
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-70561@lists.php.net to get a copy of this message
If the database is actually running, you should be able to do mysqldump to get the SQL you are missing... The errors you are getting are a result of bad code -- You should have some code like: mysql_query($query) or error_log(__FILE__ . ' ' . __LINE__ ': ' . mysql_errormessage()); (All one line) The point is to *NOT* spew out error messages to the browser which reveal far too much about your server to potential hackers. So the errors will be logged in your error_log file of Apache. Or, you could use more arguments to http://php.net/error_log to lot it anywhere you like. At a guess, I'm supposing that the MySQL server is not starting up. -- WARNING richard@zend.com address is an endangered species -- Use ceo@l-i-e.com Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm Volunteer a little time: http://chatmusic.com/volunteer.htm ----- Original Message ----- From: Viper1 <viper1@mediaone.net> Newsgroups: php.general To: <php-general@lists.php.net> Sent: Tuesday, October 09, 2001 11:02 AM Subject: Question on Database > > > I have a question about a problem I am having on a > mysql db. I have inherited a website from someone that > I can no longer get in touch with. The website is a > smaller version of Monster.com it allows user to > submit a resume and search jobs online. I am having > errors on it but I am not sure I have it all. Should > it have a *.sql file? It has only phtml,inc files also > a admin area and all the images. > > I am getting an error on index.phtml of: Warning: > Supplied argument is not a valid MySQL result resource > in C:sitessitesindex.phtml on line 7 > > and : Warning: Supplied argument is not a valid MySQL > result resource in C:sitesdocsma.inc on line 7 > > > line 7 of index is: $copy = > mysql_fetch_array($return); > > line 7 of ma.inc: $meta_row = > mysql_fetch_array($meta_return); > > Please help . Thanks.. > > > > > >

« previous php.general (#70561) next »