beebee wrote:
I've got PHP5, Apache & MySQL running on win98. I want to know if
there is a debugger available, other than from Zend?
I find the Apache error log quite useful for catching PHP errors. It's
at <install path>\Apache2\logs\error.log.
For MySQL, while developing I use a debug flag that I can set/clear to
print SQL statements to the browser immediately before sending them to
the MySQL server. I find many poorly formed queries this way. You can
also copy the SQL from the browser and paste into the MySQL Query
Browser to see what the query's actually doing. Also, ALWAYS check the
return status of MySQL calls/methods and if there's an error, print it.
E.g.:
// create SQL query
$sql = "SELECT blah, blah, blah";
if ($debug)
{
echo "<p>$sql</p>\n";
}
// execute/check the query
if (!$result = $dbo->query($sql))
{
echo "<p>output_search_results: error inserting track:<br />\n";
echo $dbo->error ."</p>\n";
exit();
}
// check for an empty result set
if ($result->num_rows == 0 )
{
blah
blah
blah
Hope that helps!
NM
--
convert uppercase WORDS to single keystrokes to reply