首页 >php教程 >php手册 >php后治理分类导航菜单

php后治理分类导航菜单

WBOY
WBOY原创
2016-06-06 19:42:471155浏览

php后管理分类导航菜单 !DOCTYPEhtmlhead meta http-equiv="Content-type" content="text/html" charset="utf-8" title后台管理折叠导航菜单/title style body{ margin【本文来自鸿网互联 (http://www.68idc.cn)】 :0 ; padding :0 ; text -align: center; fo

php后管理分类导航菜单



    <meta http-equiv="Content-type" content="text/html" charset="utf-8">
    <title>后台管理折叠导航菜单</title>
    <style><span style="color: #000000;">
        body{
            margin【本文来自鸿网互联 (http://www.68idc.cn)】:0<span style="color: #000000;">;
            padding:0<span style="color: #000000;">;
            text-align:<span style="color: #000000;">center;
            font:normal 12px Arial,Verdana,<span style="color: #000000;">Tahoma;
            line-height:150%<span style="color: #000000;">;
        }
        a:link, a:<span style="color: #000000;">visited{
            color:<span style="color: #008000;">#<span style="color: #008000;">385065;
            text-decoration:<span style="color: #000000;">none;
        }
        a:<span style="color: #000000;">hover{
            text-decoration:<span style="color: #000000;">underline;
        }
        <span style="color: #008000;">#<span style="color: #008000;">menu{
            width:<span style="color: #000000;">150px;
            margin:0<span style="color: #000000;"> 15px;
            padding:0<span style="color: #000000;">;
            text-align:<span style="color: #000000;">left;
            <span style="color: #0000ff;">list-style:<span style="color: #000000;">none;
        }
        <span style="color: #008000;">#<span style="color: #008000;">menu .item{
            background:<span style="color: #008000;">#<span style="color: #008000;">ccaaee;
            padding:<span style="color: #000000;">0px;
            <span style="color: #0000ff;">list-style:<span style="color: #000000;">none;
            border:1px solid <span style="color: #008000;">#<span style="color: #008000;">eee;
<span style="color: #000000;">        }
        a.title:link, a.title:visited, a.title:<span style="color: #000000;">hover{
            display:<span style="color: #000000;">block;
            color:<span style="color: #008000;">#<span style="color: #008000;">385065;
            font-weight:<span style="color: #000000;">bold;
            padding:2px 0 0<span style="color: #000000;"> 22px;
            width:<span style="color: #000000;">128px;
            line-height:<span style="color: #000000;">23px;
            cursor:<span style="color: #000000;">pointer;
            text-decoration:<span style="color: #000000;">none;
        }
        <span style="color: #008000;">#<span style="color: #008000;">menu .item ul{
            border:1px solid <span style="color: #008000;">#<span style="color: #008000;">9facb7;
            margin:0<span style="color: #000000;">;
            width:<span style="color: #000000;">116px;
            padding:<span style="color: #000000;">3px 0px 3px 30px;
            bakground:<span style="color: #008000;">#<span style="color: #008000;">fff;
            <span style="color: #0000ff;">list-style:<span style="color: #000000;">none;
            display:<span style="color: #000000;">none;
        }
        <span style="color: #008000;">#<span style="color: #008000;">menu .item ul li{
            display:<span style="color: #000000;">block;
        }
    </style>
    <script type="text/javascript">
        <span style="color: #0000ff;">function<span style="color: #000000;"> hideAllObj(){
            <span style="color: #0000ff;">var items = document.getElementsByClassName("option"<span style="color: #000000;">);
            <span style="color: #0000ff;">for(<span style="color: #0000ff;">var j=0; j<items.length; j++<span style="color: #000000;">){
                items[j].style.display = "none"<span style="color: #000000;">;
            }
        }

        <span style="color: #0000ff;">function<span style="color: #000000;"> check(){
            document.getElementById("opt_1").style.display = "block"<span style="color: #000000;">;
            <span style="color: #0000ff;">var items = document.getElementsByClassName("title"<span style="color: #000000;">);
            <span style="color: #0000ff;">for(<span style="color: #0000ff;">var j=0; j<items.length; j++<span style="color: #000000;">){
                items[j].onclick = <span style="color: #0000ff;">function<span style="color: #000000;">(){
                    <span style="color: #0000ff;">var obj = document.getElementById("opt_" + this.<span style="color: #000000;">name);
                    <span style="color: #0000ff;">if(obj.style.display != "block"<span style="color: #000000;">){
                        hideAllObj();
                        obj.style.display = "block"<span style="color: #000000;">;
                    }<span style="color: #0000ff;">else<span style="color: #000000;">{
                        obj.style.display = "none"<span style="color: #000000;">;
                    }
                }
            }
        }

        document.getElementsByClassName=<span style="color: #0000ff;">function<span style="color: #000000;">(classname){
            <span style="color: #0000ff;">var retnode =<span style="color: #000000;"> [];
            <span style="color: #0000ff;">var myclass = <span style="color: #0000ff;">new RegExp('\\b'+classname+'\\b'<span style="color: #000000;">);
            <span style="color: #0000ff;">var elem = this.getElementsByTagName('*'<span style="color: #000000;">);
            <span style="color: #0000ff;">for(<span style="color: #0000ff;">var j=0; j<elem.length; j++<span style="color: #000000;">){
                <span style="color: #0000ff;">var classes = elem[j].<span style="color: #000000;">className;
                <span style="color: #0000ff;">if(myclass.<span style="color: #000000;">test(classes)){
                    retnode.<span style="color: #000000;">push(elem[j]);
                }
            }
            <span style="color: #0000ff;">return<span style="color: #000000;"> retnode;
        }
    </script>


声明:
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn