学习EXTJS2_1

按照EXT风格写了一点代码:
<! DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//ZH-CN" "http://www.w3.org/TR/html4/strict.dtd" >
< html >
< head >
    
< meta  http-equiv ="Content-Type"  content ="text/html; charset=UTF-8" >
    
< title > Extjs 2.0 学习笔记 </ title >
<!-- Librarys -->
    
< link  rel ="stylesheet"  href ="../js/ext2/resources/css/ext-all.css"  type ="text/css"   />
    
< script  type ="text/javascript"  src ="../js/ext2/adapter/ext/ext-base.js" ></ script >
    
< script  type ="text/javascript"  src ="../js/ext2/ext-all.js" ></ script >
<!-- End Librarys -->
    
< style  type ="text/css" >
        html, body 
{
            font
:normal 14px verdana;
            margin
:0;
            padding
:0;
            border
:none;
            overflow
:hidden;
            height
:100%;
        
}

        body
{background:url("images/bg-body.jpg") repeat-y 0 0;}
    
</ style >
    
< script  type ="text/javascript" >
    
    
var DefaultDialog = function(config) {
        
var config = config||{}
        
var defConfig = {
            title: 
'缺省窗口',
            height: 
240,
            width: 
320,
            shadow: 
true,
            modal: 
false,
            draggable:
true,
            fixedcenter:
true,
            collapsible: 
false,
            closable: 
true,
            resizable:
false
        }

        Ext.apply(
this, config, defConfig);
        
//var el = Ext.DomHelper.append(document.body, {tag: 'div'});
        DefaultDialog.superclass.constructor.call(this, config);
    }
;
    
    Ext.extend(DefaultDialog, Ext.Window); 
// DefaultDialog extends Ext.BasicDialog

    AppStart
=function(){

        
return {
            run: 
function(){
                dlg 
= new DefaultDialog();
                dlg.show();
                dlg2 
= new DefaultDialog({title:'自定义窗',buttons:[{text:'Yes'},{text:'No'}],resizable:true,shadow : false,html:'<p>hello world</p>'}); 
                dlg2.show();
            }

        }

    }
();

    Ext.onReady(
AppStart .run, AppStart );

    
</ script >
</ head >
< body >

</ body >
</ html >
 
测试成功,继续努力!
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值