2012-01-31 57 views
0

我正在運行一個html文件,其中當我單擊提交按鈕時應打開一個新的html文件。在按鈕上打開html文件單擊Ext-JS4

這是代碼:在loginForm.html

運行 代碼
{ 
    xtype : 'button', 
    text : ' Login ', 
    formBind : true, 
    listeners : { 
     click :function(){ 
      alert(); 
      //these methods are not working 
      //Ext.getCmp('login_panel').load({url : '/smartNav/pub/html/index_dev.html', scripts : true}); 
      //Ext.getCmp('login_panel').update('index_dev.html'); 

     } 
    } 
} 

可有人建議我這可怎麼辦呢?

回答

0

你可以只使用window.open

window.open('/smartNav/pub/html/index_dev.html'); 

開新窗口或當前窗口

window.location.href='/smartNav/pub/html/index_dev.html'; 
+0

嘿,這工作改變位置,謝謝。 – techie 2012-02-01 06:13:16