jkj             Thu Feb  1 14:48:17 2001 EDT

  Modified files:              
    /phpdoc     make_chm.php 
  Log:
  - added support for Czech (tested) and for Japanese (not tested)
  - changed manual.html to $indexfile in a whole script
  
  
Index: phpdoc/make_chm.php
diff -u phpdoc/make_chm.php:1.6 phpdoc/make_chm.php:1.7
--- phpdoc/make_chm.php:1.6     Sun Jan 14 09:11:38 2001
+++ phpdoc/make_chm.php Thu Feb  1 14:48:17 2001
@@ -21,12 +21,14 @@
     // Japanese is not on my list, I don't know why...
     $languages = Array (
     
+      "cs"    => "0x405 Czech",
       "de"    => "0x407 German (Germany)",
       "en"    => "0x809 Enlish (United Kingdom)",
       "es"    => "0xc0a Spanish (International Sort)",
       "fr"    => "0x40c French (France)",
       "hu"    => "0x40e Hungarian",
       "il"    => "0x410 Italian (Italy)",
+      "ja"    => "0x411 Japanese",
       "kr"    => "0x412 Korean",
       "nl"    => "0x413 Dutch (Netherlands)",
       "pt_BR" => "0x416 Portuguese (Brazil)"
@@ -56,7 +58,7 @@
     
     // now try to find out how the manual named in the actual language
     // this must be in the manual.html file as the title (DSSSL generated)
-    $content = join("", file("$fancydir/manual.html"));
+    $content = join("", file("$fancydir/$indexfile"));
     if (preg_match("|>(.*)</TITLE|U", $content, $found)) {
       $manual_title = $found[1];
     } else { $manual_title = "PHP Manual"; }
@@ -64,7 +66,7 @@
     fputs ($f, "Title=$manual_title\n");
     
     // define the phpdoc window style (adds more functionality)
-    fputs($f , "\n[WINDOWS]\nphpdoc=\"PHP Manual\",\"manual_hu.hhc\",," .
+    fputs($f , "\n[WINDOWS]\nphpdoc=\"PHP Manual\",\"manual_$language.hhc\",," .
     
"\"$fancydir\\$indexfile\",\"$fancydir\\$indexfile\",,,,,0x23520,,0x386e,,,,,,,,0\n");
 
     // write out all the filenames as in $fancydir    
@@ -139,7 +141,7 @@
 <UL>
 <?php
   
-  $index_a = file ("$fancydir/manual.html");
+  $index_a = file ("$fancydir/$indexfile");
   $ijoin = join("", $index_a);
   $ijoin = preg_replace("/[\r|\n]/", " ", $ijoin);
   
@@ -150,7 +152,7 @@
 
   if ($fancyindex) {
     preg_match('|CLASS=\"title\" ><A NAME=\"manual\" >(.*)</A|U', $ijoin, $match);
-    SiteMapObj($match[1], "manual.html", "  ", 21);
+    SiteMapObj($match[1], "$indexfile", "  ", 21);
   }
 
   preg_match('|<A HREF="preface.html" >(.*)</A >|U', $ijoin, $match);


Reply via email to