Results 1 to 3 of 3

Thread: How to start download file from ExtGrid tab button?

  1. #1
    Sencha User
    Join Date
    Jan 2011
    Posts
    47

    Exclamation How to start download file from ExtGrid tab button?

    I try this way:

    1. I make an link <a href="./text.zip">get</a>
    2. Add this button in tab of

    Ext.grid.EditorGridPanel (

    3 this way:
    Code:
               {
                    text: 'Export records',
                    iconCls: 'icon-save',
                    handler : function(){
    
                        $("#export").click();
    
                    }
    
               }
    But this does not work for me. Pls help me - to initialise dosnload of xxxx file from tab button.

    Thank your.

  2. #2
    Sencha Premium Member steffenk's Avatar
    Join Date
    Jul 2007
    Location
    Haan, Germany
    Posts
    2,675

    Default

    jquery?

    simple example, check it in console
    Code:
    new Ext.Button ({ 
       text: 'download', 
       renderTo: Ext.getBody(),
       handler: function() {
          window.open(path-to-text.zip); 
       } 
    });
    vg Steffen
    --------------------------------------
    Release Manager of TYPO3 4.5

  3. #3
    Sencha User
    Join Date
    Jan 2011
    Posts
    47

    Default

    i try to do this with jquery, yes.
    Made already fancybox with link
    Thank your for answer.
    It works

    Code:
               {
               /* + One more check*/
    
                  text: 'Export to Excell 2007',
                  iconCls: 'icon-save',
                  renderTo: Ext.getBody(),
                  handler: function() {
                     window.open('{/literal}{$config_site_url}/admin.php?act=download{literal}'); 
                  } 
    
    
               }
    Thsnkx,
    73!

Similar Threads

  1. Start Download
    By originative in forum Ext 3.x: Help & Discussion
    Replies: 6
    Last Post: 21 Jul 2009, 12:19 PM
  2. File Download ?
    By Etienne Jouvin in forum Ext 2.x: Help & Discussion
    Replies: 7
    Last Post: 9 Nov 2008, 2:50 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •