didou           Tue Jan 25 11:39:48 2005 EDT

  Modified files:              
    /phpdoc/scripts     xml_proto.php 
  Log:
  only link to constants.xml if the file was generated
  # we need to do the same with configure.xml and ini.xml, but this script 
doesn't generate those files, suggestions ?
  
http://cvs.php.net/diff.php/phpdoc/scripts/xml_proto.php?r1=1.21&r2=1.22&ty=u
Index: phpdoc/scripts/xml_proto.php
diff -u phpdoc/scripts/xml_proto.php:1.21 phpdoc/scripts/xml_proto.php:1.22
--- phpdoc/scripts/xml_proto.php:1.21   Tue Jan 25 11:18:26 2005
+++ phpdoc/scripts/xml_proto.php        Tue Jan 25 11:39:48 2005
@@ -16,7 +16,7 @@
   | Authors:   Brad House <[EMAIL PROTECTED]>                             |
   +----------------------------------------------------------------------+
  
-  $Id: xml_proto.php,v 1.21 2005/01/25 16:18:26 didou Exp $
+  $Id: xml_proto.php,v 1.22 2005/01/25 16:39:48 didou Exp $
 */
 
 /*
@@ -139,7 +139,7 @@
   }
 
   fwrite($fp, '<?xml version="1.0" encoding="iso-8859-1"?>'."\n" .
-       '<!-- $Revision: 1.21 $ -->'."\n" .
+       '<!-- $Revision: 1.22 $ -->'."\n" .
        "<!-- Generated by xml_proto.php v" . $version . ". Found in /scripts 
directory of phpdoc. -->\n" .
        "<reference id=\"ref." . $extension_name . "\">\n" .
        " <title>$extension_name Functions</title>\n" .
@@ -169,10 +169,12 @@
        "    Type of resource types (link id, etc.) this extension returns.\n" .
        "    &no.resources;\n" .
        "   </para>\n" .
-       "  </section>\n" .
-       "  <!-- Information found in constants.xml -->\n" .
-       "  &reference." . $extension_name . ".constants;\n" .
-       " </partintro>\n" .
+       "  </section>\n");
+       if ($num_const > 0) {
+         fwrite($fp, "  <!-- Information found in constants.xml -->\n" .
+                     "  &reference." . $extension_name . ".constants;\n");
+       }
+       fwrite($fp, " </partintro>\n" .
        " &reference." . $extension_name . ".functions;\n" .
        "</reference>\n\n" .
        "<!-- Keep this comment at the end of the file\n" .
@@ -222,7 +224,7 @@
     $functype = trim($funclist[$i]["function_type"]);
 
     fwrite($fp, '<?xml version="1.0" encoding="iso-8859-1"?>'."\n" .
-               '<!-- $Revision: 1.21 $ -->'."\n" .
+               '<!-- $Revision: 1.22 $ -->'."\n" .
                "<!-- Generated by xml_proto.php v" . $version . ". Found in 
/scripts directory of phpdoc. -->\n" .
                "<refentry id=\"function." . $fixname . "\">\n" .
                " <refnamediv>\n" .

Reply via email to