梦幻之旅

DEBUG - 天道酬勤

   :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  671 随笔 :: 6 文章 :: 256 评论 :: 0 Trackbacks
<%@ page contentType="text/html;charset=UTF-8"%>
<html>
    
<head>
        
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        
<title>Ext.Window</title>
        
<link rel="stylesheet" type="text/css"
            href
="/ext/resources/css/ext-all.css" />
        
<script type="text/javascript" src="/ext/adapter/ext/ext-base.js"></script>
        
<script type="text/javascript" src="/ext/ext-all.js"></script>
        
<script type="text/javascript">
             
function myWindow()
             {
                 
var tabPanel=new Ext.TabPanel(
                         {
                             width:
300,
                             height:
200,
                             items:[
                                    {
                                        contentEl:
"tabOne",//标签页的页面元素id(加入你想显示的话)
                                        title:"HuyVanpull's Panel",
                                         activeTab:
1//当前激活标签
                                         height:30,
                                         closable:
true
                                    },
                                    {
                                        contentEl:
"tabTwo",//标签页的页面元素id(加入你想显示的话)
                                        title:"Hui Wanpeng's Panel",
                                         height:
30,
                                         closable:
true
                                    }

                                  ]
                         });
                
//window组件,它继承自pane.
                var win=new Ext.Window(
                        {
                               contentEl:
"container",
                               width:
300,
                               height:
200,
                               items:tabPanel,
                               plain:
true,//true则主体背景透明,false则主体有小差别的背景色,默认为false
                               title:"My Window",
                               buttons:[{text:
"OK"},{text:"CANCEL",handler:function(){win.close();}}],
                               buttonAlign:
"center",
                               collapsible:
true
                        });
                win.show();
             }
             Ext.onReady(myWindow); 
        
</script>
    
</head>
    
<body>
        
<div id="container"></div>
        
<div id="tabOne" class="x-hide-display">
            i am Huyvanpull!
        
</div>
        
<div id="tabTwo" class="x-hide-display">
            i am Hui Wanpeng!
        
</div>
    
</body>
</html>
posted on 2008-10-22 09:12 HUIKK 阅读(1904) 评论(0)  编辑  收藏 所属分类: EXT

只有注册用户登录后才能发表评论。


网站导航: