zoukankan      html  css  js  c++  java
  • 尚学堂的一个用了ExtJs的页面代码

    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=GB18030" />
            <title>北京尚学堂BBS2009论坛管理平台</title>
            <link rel="stylesheet" type="text/css"
                href="ext/resources/css/ext-all.css" />
            <!-- GC -->
            <!-- LIBS -->
            <script type="text/javascript" src="ext/adapter/ext/ext-base.js">
       
    </script>
            <!-- ENDLIBS -->
            <script type="text/javascript" src="ext/ext-all.js">
       
    </script>

            <script type="text/javascript" src="ext/ext-lang-zh_CN.js">
       
    </script>
            <style type="text/css">
    html,body {
        font: normal 12px verdana;
        margin: 0;
        padding: 0;
        border: 0 none;
        overflow: hidden;
        height: 100%;
    }

    .empty .x-panel-body {
        padding-top: 0;
        text-align: center;
        font-style: italic;
        color: gray;
        font-size: 11px;
    }

    .x-btn button {
        font-size: 14px;
    }

    .x-panel-header {
        font-size: 14px;
    }
    </style>
    <script type="text/javascript">
        Ext.onReady( function() {
            //Ext.Msg.alert('ext','welcome you!');
            var addPanel = function(btn, event) {
                var n;
                n = tabPanel.getComponent(btn.id);
                if(n) {
                    tabPanel.setActiveTab(n);
                    return;
                }
                n = tabPanel.add( {
                    id : btn.id,
                    title : btn.id,
                    html : '<iframe width=100% height=100% src=' + btn.id + ' />',
                    //autoLoad : '',
                    closable : 'true'
                });
                tabPanel.setActiveTab(n);
            }

            var item1 = new Ext.Panel( {
                title : 'Category管理',
                //html : '&lt;empty panel&gt;',
                cls : 'empty',
                items : [
                    new Ext.Button({
                        id : 'Category_list',
                        text : 'Category列表',
                        width : '100%',
                        listeners : {
                            click : addPanel
                        }

                    }),

                    new Ext.Button({
                        id : 'test',
                        text : 'Test',
                        width : '100%',
                        listeners : {
                            click : addPanel
                        }

                    })

                    ]
            });

            var item2 = new Ext.Panel( {
                title : 'Accordion Item 2',
                html : '&lt;empty panel&gt;',
                cls : 'empty'
            });

            var item3 = new Ext.Panel( {
                title : 'Accordion Item 3',
                html : '&lt;empty panel&gt;',
                cls : 'empty'
            });

            var item4 = new Ext.Panel( {
                title : 'Accordion Item 4',
                html : '&lt;empty panel&gt;',
                cls : 'empty'
            });

            var item5 = new Ext.Panel( {
                title : 'Accordion Item 5',
                html : '&lt;empty panel&gt;',
                cls : 'empty'
            });

            var accordion = new Ext.Panel( {
                region : 'west',
                margins : '5 0 5 5',
                split : true,
                width : 210,
                layout : 'accordion',
                items : [ item1, item2, item3, item4, item5 ]
            });

            var tabPanel = new Ext.TabPanel( {
                region : 'center',
                enableTabScroll : true,
                deferredRender : false,
                activeTab : 0,
                items : [ {

                    title : 'index',

                    //html : 'aaaaaa'
                    autoLoad : 'Category_add.jsp'
                } ]
            });

            var viewport = new Ext.Viewport( {
                layout : 'border',
                items : [ accordion, tabPanel ]
            });

        });
    </script>
        </head>
        <body>
           
            <!-- EXAMPLES -->
        </body>
    </html>

  • 相关阅读:
    Linux 安全工具之extundelete误删除恢复
    Linux安全工具之fail2ban防爆力破解
    构建高效安全的Nginx Web服务器
    必读说明
    U盘因格式化 NTFS 中断造成无法识别,生产平台同样无法识别的修复处理方案
    计算机等级考试【二级C语言程序设计】知识点整理
    MD 使用 i5ting_toc 转换成 HTML
    Windows10 图标变白修复
    【已解决】老型号电脑需要按F1键才能进入系统
    【已解决】什么是心跳包?
  • 原文地址:https://www.cnblogs.com/flying607/p/3471937.html
Copyright © 2011-2022 走看看