cvs: docweb /www checkent.php

From: Date: Sun, 02 Mar 2008 06:17:03 +0000
Subject: cvs: docweb /www checkent.php
Groups: php.doc.web 
Request: Send a blank email to doc-web+get-975@lists.php.net to get a copy of this message
philip Sun Mar 2 06:17:03 2008 UTC Modified files: /docweb/www checkent.php Log: Added a little error handling, as some projects don't use this feature http://cvs.php.net/viewvc.cgi/docweb/www/checkent.php?r1=1.4&r2=1.5&diff_format=u Index: docweb/www/checkent.php diff -u docweb/www/checkent.php:1.4 docweb/www/checkent.php:1.5 --- docweb/www/checkent.php:1.4 Tue Jan 25 19:52:55 2005 +++ docweb/www/checkent.php Sun Mar 2 06:17:03 2008 @@ -17,7 +17,7 @@ | Mehdi Achour <didou@php.net> | | Sean Coates <sean@php.net> | +----------------------------------------------------------------------+ -$Id: checkent.php,v 1.4 2005/01/25 19:52:55 sean Exp $ +$Id: checkent.php,v 1.5 2008/03/02 06:17:03 philip Exp $ */ require_once '../include/init.inc.php'; @@ -38,7 +38,17 @@ FROM meta_info "; -list($startTime, $endTime, $schemes) = sqlite_fetch_array(sqlite_query($sqlite, $sql)); + +$metaQ = sqlite_query($sqlite, $sql); +if (!$metaQ) { + echo site_header('docweb.common.header.checkent'); + echo '<p>No meta info about this project was found to check.</p>'; // @@@ template this + echo site_footer(); + exit(); + +} + +list($startTime, $endTime, $schemes) = sqlite_fetch_array($metaQ); $entData = array(); $sql = " @@ -51,7 +61,16 @@ ORDER BY check_result, entity "; + $urlsQ = sqlite_query($sqlite, $sql); +if (!$urlsQ) { + echo site_header('docweb.common.header.checkent'); + echo '<p>No URLs for this project were found to check.</p>'; // @@@ template this + echo site_footer(); + exit(); + +} + while ($row = sqlite_fetch_array($urlsQ)) { $entData[$row['check_result']][] = $row; }

« previous php.doc.web (#975) next »