title: EXTJS & PHP Upload file
body: <p>I use the UploadFile example in EXTJS (<a href="http://dev.sencha.com/deploy/dev/examples/form/file-upload.html" rel="nofollow noreferrer">http://dev.sencha.com/deploy/dev/examples/form/file-upload.html</a>) but I don't know what to write in the server side to save the uploaded file (in php) 
  help me please</p>
  
  <p>My client side code is : </p>
  
  <pre><code>var fp = new Ext.FormPanel({
      //renderTo: 'fi-form',
      fileUpload: true,
      width: 500,
      frame: true,
      title: 'File Upload Form',
      autoHeight: true,
      bodyStyle: 'padding: 10px 10px 0 10px;',
      labelWidth: 50,
      defaults: {
          anchor: '95%',
          allowBlank: false,
          msgTarget: 'side'
      },
      items: [{
          xtype: 'fileuploadfield',
          id: 'form-file',
          emptyText: 'Select an image',
          fieldLabel: 'Photo',
          name: 'photo-path',
          buttonText: '',
          buttonCfg: {
              iconCls: 'upload-icon'
          }
      }],
      buttons: [{
          text: 'Save',
          handler: function(){
              if(fp.getForm().isValid()){
                      fp.getForm().submit({
                          url: 'php/file-upload.php',
                          waitMsg: 'Uploading your photo...',
                          success: function(fp, o){
                              msg('Success', 'Processed file');
                          }
                      });
              }
          }
      },{
          text: 'Reset',
          handler: function(){
              fp.getForm().reset();
          }
      }]
  });
  </code></pre>