newWin(){varwin=newExt.Window({title:"窗口",wi" />

亚洲免费在线-亚洲免费在线播放-亚洲免费在线观看-亚洲免费在线观看视频-亚洲免费在线看-亚洲免费在线视频

EXT之window動態加載頁面

系統 2474 0

首先看下普通的窗口:

Js代碼
  1. function <wbr>newWin()<wbr>{<wbr><wbr><wbr><wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> var <wbr>win=</wbr> new <wbr>Ext.Window({title:</wbr> "窗口" ,<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>width:400,<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>height:300,<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>maximizable:</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> true });<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win.show();<wbr>}<wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr>這樣就是一個簡單的窗口,里面不含任務內容。可以讓它請求一個頁面:</wbr>

Js代碼
  1. var <wbr>win; <wbr><wbr></wbr></wbr></wbr>
  2. function <wbr>newWin(value)<wbr>{ <wbr><wbr></wbr></wbr></wbr></wbr>
  3. <wbr><wbr><wbr><wbr></wbr></wbr></wbr></wbr> //<wbr>如果窗口存在,顯示</wbr> <wbr><wbr></wbr></wbr>
  4. <wbr><wbr><wbr><wbr>win<wbr>=<wbr>Ext.getCmp(</wbr></wbr></wbr></wbr></wbr></wbr> "win" ); <wbr><wbr></wbr></wbr>
  5. <wbr><wbr><wbr><wbr></wbr></wbr></wbr></wbr> if <wbr>(win)<wbr>{ <wbr><wbr></wbr></wbr></wbr></wbr>
  6. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win.show(); <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  7. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win.load({ <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  8. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>url<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "../TeacherDispatchAction.do?method=courseDetail" , <wbr><wbr></wbr></wbr>
  9. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>params<wbr>:<wbr>{ <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  10. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>couId<wbr>:<wbr>value, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  11. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>subMainId<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "tab-" <wbr>+<wbr>value<wbr>+<wbr></wbr></wbr></wbr></wbr> "-main" <wbr><wbr></wbr></wbr>
  12. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>} <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  13. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>}); <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  14. <wbr><wbr><wbr><wbr>}<wbr></wbr></wbr></wbr></wbr></wbr> else <wbr>{ <wbr><wbr></wbr></wbr></wbr>
  15. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win<wbr>=<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> new <wbr>Ext.Window({ <wbr><wbr></wbr></wbr></wbr>
  16. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>title<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "課程信息" , <wbr><wbr></wbr></wbr>
  17. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>id<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> 'win' , <wbr><wbr></wbr></wbr>
  18. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>width<wbr>:<wbr>400, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  19. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>height<wbr>:<wbr>300, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  20. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>maximizable<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> true , <wbr><wbr></wbr></wbr>
  21. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>closable<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> true , <wbr><wbr></wbr></wbr>
  22. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>closeAction<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> 'close' <wbr><wbr></wbr></wbr>
  23. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>}); <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  24. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win.show(); <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  25. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>win.load({ <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  26. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>url<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "../TeacherDispatchAction.do?method=courseDetail" , <wbr><wbr></wbr></wbr>
  27. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>params<wbr>:<wbr>{ <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  28. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>couId<wbr>:<wbr>value, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  29. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>subMainId<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "tab-" <wbr>+<wbr>value<wbr>+<wbr></wbr></wbr></wbr></wbr> "-main" <wbr><wbr></wbr></wbr>
  30. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>}, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  31. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>scripts:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> true <wbr><wbr></wbr></wbr>
  32. <wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>}); <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  33. <wbr><wbr><wbr><wbr>} <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  34. }<wbr><wbr></wbr></wbr>

<wbr></wbr>

這里的條件語句是用來作判斷,我所實現的是只打開一個窗口,根據要求動態加載頁面的內容。

Js代碼
  1. win.load({ <wbr><wbr></wbr></wbr>
  2. <wbr><wbr><wbr><wbr><wbr>url<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "../TeacherDispatchAction.do?method=courseDetail" , <wbr><wbr></wbr></wbr>
  3. <wbr><wbr><wbr><wbr><wbr>params<wbr>:<wbr>{ <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  4. <wbr><wbr><wbr><wbr><wbr><wbr>couId<wbr>:<wbr>value, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  5. <wbr><wbr><wbr><wbr><wbr><wbr>subMainId<wbr>:<wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr> "tab-" <wbr>+<wbr>value<wbr>+<wbr></wbr></wbr></wbr></wbr> "-main" <wbr><wbr></wbr></wbr>
  6. <wbr><wbr><wbr><wbr><wbr>}, <wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
  7. <wbr><wbr><wbr><wbr><wbr>scripts:<wbr></wbr></wbr></wbr></wbr></wbr></wbr> true <wbr><wbr></wbr></wbr>
  8. <wbr><wbr><wbr><wbr>});<wbr><wbr></wbr></wbr></wbr></wbr></wbr></wbr>

這句就是用來實現加載的語句。 注意:如果請求的頁面里也包含EXT組件的話, scripts: true 不能丟掉。否則就不會顯示啦。

Ext.Window的屬性有:

closable : true,<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>//是否可關閉</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

closeAction : 'close'<wbr>關閉窗口是銷毀窗口,為'hide'則隱藏</wbr>

maximizable : true,<wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr><wbr>//是否可最大化<br> draggable:false,//拖動<br><wbr>resizable:false //變大小</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

EXT之window動態加載頁面


更多文章、技術交流、商務合作、聯系博主

微信掃碼或搜索:z360901061

微信掃一掃加我為好友

QQ號聯系: 360901061

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描下面二維碼支持博主2元、5元、10元、20元等您想捐的金額吧,狠狠點擊下面給點支持吧,站長非常感激您!手機微信長按不能支付解決辦法:請將微信支付二維碼保存到相冊,切換到微信,然后點擊微信右上角掃一掃功能,選擇支付二維碼完成支付。

【本文對您有幫助就好】

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描上面二維碼支持博主2元、5元、10元、自定義金額等您想捐的金額吧,站長會非常 感謝您的哦!!!

發表我的評論
最新評論 總共0條評論
主站蜘蛛池模板: 成年性视频bbixx | 国产午夜精品一区二区 | 亚洲成人高清在线 | 一级特级女人18毛片免费视频 | 日日摸狠狠的摸夜夜摸 | 国产亚洲欧美日韩v在线 | 久青草国产手机视频免费观看 | 国内精品伊人久久久影院 | 日韩免费影视 | 久久国产精品只做精品 | 欧美日韩免费做爰视频 | 国产一级特黄全黄毛片 | 久久精品三级视频 | 一级作爱视频免费观看 | 国产青草视频免费观看97 | 久久久久久免费视频 | 中文国产成人精品久久久 | 玖玖免费| 亚洲国产精久久久久久久春色 | 日韩中文字幕视频在线 | 一级片按摩 | 亚洲国产视频在线 | 久久青草免费视频 | 自拍视频国产 | 色播影音 | 91亚洲国产系列精品第56页 | 精品夜夜春夜夜爽久久 | 国产精品免费视频播放 | 91精品久久国产青草 | 奇米影视777欧美在线观看 | 日本欧美在线观看 | 久久久91精品国产一区二区 | 免费国产成人午夜在线观看 | 国产综合婷婷 | 天天射天天射天天射 | 欧美一级高清毛片aaa | 日韩天堂视频 | 久久88香港三级台湾三级中文 | 写真福利 第 页 在线视频 | 99精品国产成人a∨免费看 | 亚洲综合狠狠99婷婷 |