/[LeafOK_CVS]/fenglin/bbs/display_doc.php
ViewVC logotype

Annotation of /fenglin/bbs/display_doc.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (hide annotations)
Sun Apr 6 03:50:01 2025 UTC (11 months, 1 week ago) by sysadm
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +0 -0 lines
FILE REMOVED
Remove legacy code

1 sysadm 1.1 <?
2     $xmlfiles = array(
3     "./doc/management.xml",
4     "./doc/bbs_master.xml",
5     "./doc/board_manage.xml"
6     );
7    
8     $xslfile = "./doc/bbs_xml_doc.xsl";
9    
10     $xsl = new DOMDocument;
11     $xsl->load($xslfile);
12    
13     // Configure the transformer
14     $proc = new XSLTProcessor;
15     $proc->importStyleSheet($xsl); // attach the xsl rules
16    
17     foreach ($xmlfiles as $xmlfile)
18     {
19     $htmlfile = str_replace(".xml", ".html", $xmlfile);
20    
21     // Load the XML source
22     $xml = new DOMDocument;
23     $xml->load($xmlfile);
24    
25     $domdoc = $proc->transformToDoc($xml);
26     $domdoc->saveHTMLFile($htmlfile);
27     }
28     ?>

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1