SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Evangelist
    Join Date
    Jun 2001
    Location
    London
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Download file request from browser

    Hi,

    I am trying to trigger the download of a file from the browser (at the moment a word file!).

    But when I supply the link as an '<a href='...'>' html tag the document appears in the browser. Although this is quite good I unfortunately need to open up the download dialog box.

    Any ideas or am I missing something very simple!!!

    Cheers

  2. #2
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    700
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi addstravel,

    Unfortunately for you, browsers tend to display any and all documents they recognize. This includes (dependent upon the browser) *.doc, *.bmp, *.xls, and any other extension for which it has a plug-in. If you want your visitor to download a Word document, you need to zip it (WinZip, etal) and then point to it: <a href="someName.zip">

    Vinny
    Where the World Once Stood
    the blades of grass
    cut me still

  3. #3
    SitePoint Evangelist
    Join Date
    Jun 2001
    Location
    London
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thanks but what about...

    Thanks for the posting, however, how do sites that suggest downloading a pdf document manage to trigger to user to download the file and not display it in the browser?

    Anyone?


Bookmarks

Posting Permissions

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