按照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>
测试成功,继续努力!

































































测试成功,继续努力!