| +----------------------------------------------------------------------+ $Id$ */ /** * @todo * Add support for online doc editing * Add count of "perfect" functions * Get this on https://doc.php.net/ */ $errors = array( 'undoc' => array( 'label' => 'Not documented', 'description' => 'These are the undocumented functions: The function which XML skeleton is in CVS, and contain &warn.undocumented.func;' ), 'oldstyle' => array( 'label' => 'Old style', 'description' => 'These functions are not converted to the new doc style yet, and thus, are not checked', ), 'badorder' => array( 'label' => 'Bad refsect1 order', 'description' => 'These functions are converted to the new doc style, but the refsect1 are not well ordered', ), 'noparameters' => array( 'label' => 'No parameters', 'description' => 'These functions lacks parameters description.', ), 'noreturnvalues' => array( 'label' => 'No return values', 'description' => 'These functions lacks return values information', ), 'noexamples' => array( 'label' => 'No examples', 'description' => 'These functions lacks examples.', ), 'nochangelog' => array( 'label' => 'No changelog section', 'description' => 'These functions lacks changelog refsect1 while metionning "PHP \d" in the XML source.', ), 'noerrors' => array( 'label' => 'No errors section', 'description' => 'These functions lacks errors information.', ), 'noseealso' => array( 'label' => 'No see also', 'description' => 'These functions lacks link to other functions/sections. You may consider adding some cross links to point readers to valuable resources.', ), 'roleerror' => array( 'label' => 'Refsect1 role error', 'description' => 'One or more <refsect1> tags use an unknown role attribute value', ), ); $restrict = (isset($_GET['restrict']) && isset($errors[$_GET['restrict']])) ? $_GET['restrict'] : false; echo '' . "\n"; ?>
This script parses the reference/ directory of the PHPDOC module and checks for common problems in the documentation. For now, supported tests are:
| Extension | '; $order = ($order == 'ASC') ? 'DESC' : 'ASC'; foreach ($errors as $type => $info) { echo "{$info['label']} | "; } echo '
| $extension | "; foreach ($errors as $type => $info) { echo "' . $stats['SUM(' . $type . ')'] . '' : '> '). " | "; } echo "
'; foreach ($status as $extension => $functions) { $nb = count($functions); if ($nb != 0) { $funcn += $nb; $exts .= '' . $extension . ' '; } } echo "$funcn functions from " . count($status) . " extensions: $exts"; echo '
'; echo '| ' . $extension . ' (' . count($functions) . ') | |||
| $function | "; if ($i % 4 == 0) { echo '|||