자바스크립트/Ext JS2011. 6. 27. 17:32
Ext.Ajax.request({
    url: 'gen-invoice-grid.php',
    // send additional parameters to instruct server script
    params: {
        startDate: Ext.getCmp('start-date').getValue(),
        endDate: Ext.getCmp('end-date').getValue()
    },
    // process the response object to add it to the TabPanel:
    success: function(xhr) {
        var newComponent = eval(xhr.responseText); // see discussion below
        myTabPanel.add(newComponent); // add the component to the TabPanel
        myTabPanel.setActiveTab(newComponent);
    },
    failure: function() {
        Ext.Msg.alert("Grid create failed", "Server communication failure");
    }
});

'자바스크립트 > Ext JS' 카테고리의 다른 글

경고창에 이벤트 주기  (0) 2011.07.01
form 요소 전체 보기  (0) 2011.07.01
ajax를 통해 extjs 코드 가져오기  (0) 2011.06.27
isReader'은(는) null 이거나 개체가 아닙니다.  (3) 2011.06.22
[ExtJS] Proxy  (0) 2011.05.21
Posted by 베니94