[ASP/VBscript] Forcing download of TXT files

Ask a Question related to Dreamweaver AppDev, Design and Development.

  1. #1

    Default [ASP/VBscript] Forcing download of TXT files

    How can I force the download of TXT files instead of the browser automatically opening them when clicking on their name/URL?

    --
    Marja Ribbers-de Vroed

    Company website:
    [url]www.webwaresystems.nl[/url]
    Dreamweaver extensions:
    [url]www.flevooware.nl/dreamweaver/[/url]


    Marja Ribbers Guest

  2. Similar Questions and Discussions

    1. No Files for download...?
      just got a new pc so im reinstalling everything. went to download the latest flash player but the link to the .exe doesnt work!? ...
    2. Unable to download files with IE
      I've got a strange bug with IE. Whenever I try and download a file, it goes through the motions of downloading as expected, but as soon as it...
    3. Select files to download
      Hi all, i have made a page with several photos of a party. There is a index in the page, and under each thumbnail there is a checkbox. With them...
    4. Forcing export "FRAMES TO FILES" in a BATCH process?
      Is there a way to force export to use "frames to files" WHEN USED IN A BATCH PROCESS? I need to create a command or batch script to export...
    5. Forcing File Download Save/Open dialogue
      I'm downloading a file using HTML <a> href. If it is a "known" file type, then the file opens in that applications window ( a Word .doc for...
  3. #2

    Default Re: [ASP/VBscript] Forcing download of TXT files

    On Wed, 16 Mar 2005 14:33:41 +0100, Marja Ribbers
    <marja@nospam.flevooware.nl> wrote:
    > How can I force the download of TXT files instead of the browser
    > automatically opening them when clicking on their name/URL?
    >
    Get them on Zip file. The way the browser interpret the file process is
    decided on the client side (meaning each user's individual browser
    setting). This settings can't and shouldn't be modified by the page but
    the user.

    If you want to open it on notepad you need to edit the file-types with
    extensions such as *.log or zip them into a downloable file.

    --
    Alexandro Colorado
    ------------------------------
    Support Engineer
    InterAKT Online
    [url]http://www.interaktonline.com[/url]
    Tel: 40(21) 312.5312
    Alexandro Colorado Guest

  4. #3

    Default Re: [ASP/VBscript] Forcing download of TXT files

    Hi Marja,

    Presuming ASP/VBS, try Tom Muck's Force Download extension:

    [url]http://www.tom-muck.com/extensions/help/ForceDownload/[/url]

    If you're using another server model, create an ASP/VBS page using the
    extension and take a look at the code it creates. It's essentially an HTML
    header being set that forces the content type to something else the browser
    wants to open/download. You could do the same for PHP or what-have-you :-)

    Best regards,
    Chris


    Chris In Madison Guest

  5. #4

    Default Re: [ASP/VBscript] Forcing download of TXT files

    Thanks, I will check it out.

    --
    Marja Ribbers-de Vroed

    Company website:
    [url]www.webwaresystems.nl[/url]
    Dreamweaver extensions:
    [url]www.flevooware.nl/dreamweaver/[/url]


    "Chris In Madison" <cowens@cnwGOAWAYDIRTYRATSPAMMERS.com> wrote in message news:d19h8e$hkv$1@forums.macromedia.com...
    > Hi Marja,
    >
    > Presuming ASP/VBS, try Tom Muck's Force Download extension:
    >
    > [url]http://www.tom-muck.com/extensions/help/ForceDownload/[/url]
    >
    > If you're using another server model, create an ASP/VBS page using the
    > extension and take a look at the code it creates. It's essentially an HTML
    > header being set that forces the content type to something else the browser
    > wants to open/download. You could do the same for PHP or what-have-you :-)
    >
    > Best regards,
    > Chris
    >
    >
    Marja Ribbers Guest

  6. #5

    Default Re: [ASP/VBscript] Forcing download of TXT files

    Works fantastic... thank you for the tip!

    --
    Marja Ribbers-de Vroed

    Company website:
    [url]www.webwaresystems.nl[/url]
    Dreamweaver extensions:
    [url]www.flevooware.nl/dreamweaver/[/url]

    Marja Ribbers Guest

  7. #6

    Default Re: [ASP/VBscript] Forcing download of TXT files

    You're welcome :-) It's been a very handy tool for me, too. Especially
    when generating CSV files on the fly.

    ~Chris


    Chris In Madison Guest

  8. #7

    Default Re: [ASP/VBscript] Forcing download of TXT files

    > Especially when generating CSV files on the fly.

    That type of thing is exactly what I needed this for: to download all sorts of (ascii) files that are generated on the fly by my web application.

    --
    Marja Ribbers-de Vroed

    Company website:
    [url]www.webwaresystems.nl[/url]
    Dreamweaver extensions:
    [url]www.flevooware.nl/dreamweaver/[/url]

    Marja Ribbers Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139