For Programmers: Free Programming Magazines  


Home > Archive > PHP Mirrors > July 2004 > #29412 [NEW]: quickref.php E_ALL fixes









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author #29412 [NEW]: quickref.php E_ALL fixes
Toni Dot Viemero At Iki Dot Fi

2004-07-27, 3:58 pm

From: toni dot viemero at iki dot fi
Operating system: Irrelevant
PHP version: 4.3.8
PHP Bug Type: Website problem
Bug description: quickref.php E_ALL fixes

Description:
------------
Calling quickref.php directly gives couple of thousand "Undefined
variable: notfound" rows in PHP.net mirrors error_log.

Here's a quick'n'dirty patch to fix it:

--- /home/www/php.selfdestruct.net/docs/quickref.php Mon Jan 19
19:13:12 2004
+++ quickref.php Tue Jul 27 21:12:03 2004
@@ -24,6 +24,11 @@
define("COLUMNS", 3);
define("SHOW_CLOSE", 20);

+// Set empty $notfound if called directly
+if (!isset($notfound)) {
+ $notfound = '';
+}
+
// Print out the table of found (or all) functions. The HTML comments
are
// needed to support MyCroft search (Mozilla browser family and Sherlock
for MacOSX)
function quickref_table($functions)
@@ -75,7 +80,7 @@
$functions[$entry] = $funcname;

// Compute similarity of the name to the requested one
- if (function_exists('similar_text') && $notfound) {
+ if (function_exists('similar_text') && !empty($notfound)) {
similar_text($funcname, $notfound, $p);
$temp[$entry] = $p;
}
@@ -117,7 +122,7 @@

<h1>PHP Function List</h1>

-<?php if ($notfound && count($maybe) > 0) { ?>
+<?php if (!empty($notfound) && count($maybe) > 0) { ?>

<p>
Sorry, but the function <b><?php echo htmlspecialchars($notfound);
?></b>



--
Edit bug report at http://bugs.php.net/?id=29412&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=29412&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=29412&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=29412&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=29412&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=29412&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=29412&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=29412&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=29412&r=support
Expected behavior: http://bugs.php.net/fix.php?id=29412&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=29412&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=29412&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=29412&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=29412&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=29412&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=29412&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=29412&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=29412&r=float
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com