Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have a GeoExt form and want to do file upload here. But i never work with GeoEXT. I have this.

buttons: [{
text: 'Загрузить',
handler: function(){
if(fp.getForm().isValid() && Ext.getCmp('opinions').getValue()=="blabla"){
form_action=1;
fp.getForm().submit({
         url: '<portlet: actionURL>',
         waitMsg: 'WAITING...',
 success: function(fp, o) {
          DO SOMETHING
          }
         }
        }
      }]

This is correct? What arguments use in success: function(fp, o)? First argument is FormPanel but i dont understand what is second. Another question how to do asynchronous file upload in this case?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

i think "o" is result of your process. if not, you can easily learn what it is with firebug...

  ...  
  success: function(fp, o) {
      consolo.log(o)
                 };

and you can check out exm. about file upload with geoext here.

i hope it helps you...

share|improve this answer
    
Yes, thank you. File upload with this library really simple. –  Kliver Max Jul 4 '12 at 8:56
    
And another question what is form_action=1;? cant find this in GeoEXT documentations. Looks like simple variable. Its impotant thing to form submit? –  Kliver Max Jul 4 '12 at 11:00
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.