http://xiaocon.51.net/tree/tree.htm 或 http://xiaocon.51.net/tree/navi.xml " target=_blank> http://xiaocon.51."/> http://xiaocon.51.net/tree/tree.htm 或 http://xiaocon.51.net/tree/navi.xml " target=_blank> http://xiaocon.51.">
Home > Backend Development > PHP Tutorial > 我也贴一个,用的时候只要配制好xml文件就行了,连程序都不用改_PHP

我也贴一个,用的时候只要配制好xml文件就行了,连程序都不用改_PHP

WBOY
Release: 2016-06-01 12:41:12
Original
900 people have browsed it

使用时需要加载XSLT模块,程序下载地址:http://xiaocon.51.net/tree/tree.zip
演示地址:
http://xiaocon.51.net/tree/tree.htm
" target=_blank>
http://xiaocon.51.net/tree/tree.htm


http://xiaocon.51.net/tree/navi.xml
" target=_blank>
http://xiaocon.51.net/tree/navi.xml

51.net上不支持xslt :(
程序文件:
===========================================================
$xslstring = implode(',file("navigator.xsl"));
$xmlstring = implode(',file("navi.xml"));
$arguments = array(
     '/_xml' => $xmlstring,
     '/_xsl' => $xslstring
);

$xh = xslt_create();

$result = xslt_process($xh, 'arg:/_xml', 'arg:/_xsl', NULL, $arguments);
if ($result) {
    print $result;
}
else {
    print "Err";
    
}
xslt_free($xh);

?>
xml文件
===========================================================




    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    



XSLT文件

============================================================


    
    

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template