topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Tuesday April 16, 2024, 2:39 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Bizarre Firefox Behaviour  (Read 3360 times)

Renegade

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 13,288
  • Tell me something you don't know...
    • View Profile
    • Renegade Minds
    • Donate to Member
Bizarre Firefox Behaviour
« on: March 16, 2011, 07:10 AM »
I wrote this a short while ago:

http://cynic.me/2011...-this-internet-site/

Internet Explorer 7/8 throws an error when you pop a download through a meta refresh or iframe. The error message looks like this (I’ve blurred the domain as it’s not public yet):

Internet Explorer - Unable to open this Internet site

Searching around didn’t reveal anything of any particular use. Most “solutions” were for clients, which when you’re running a server, doesn’t help much.

Anyways, I decided to go back to basics, and try something really simple… Change the MIME type.

While the MIME type should be “application/octet-stream” for a binary setup file (program installer). However, simply changing it to “application/zip” fixes the problem in Internet Explorer, and popping meta refresh downloads then works.


Well, it was working properly... However, today I noticed that Firefox downloads it then adds a ".zip" extension. WTF? That's very odd. (It didn't before.)

Anyways, I fixed it to be a conditional download, but it just seems wrong that a browser would take it upon itself to rename files.

Is it just me, or is that odd?

Slow Down Music - Where I commit thought crimes...

Freedom is the right to be wrong, not the right to do wrong. - John Diefenbaker

housetier

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 1,321
    • View Profile
    • Donate to Member
Re: Bizarre Firefox Behaviour
« Reply #1 on: March 16, 2011, 11:15 AM »
Maybe FF renamed the file according to MIME-type?

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: Bizarre Firefox Behaviour
« Reply #2 on: March 16, 2011, 12:26 PM »
Maybe FF renamed the file according to MIME-type?
Yes, but is that proper behavior? I think that's what Renegade is asking :)
- carpe noctem

Renegade

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 13,288
  • Tell me something you don't know...
    • View Profile
    • Renegade Minds
    • Donate to Member
Re: Bizarre Firefox Behaviour
« Reply #3 on: March 16, 2011, 07:24 PM »
Maybe FF renamed the file according to MIME-type?
Yes, but is that proper behavior? I think that's what Renegade is asking :)

Exactly.

As far as I can see, it's simply flat out wrong. A file extension has no necessary connection to the content. e.g. DOCX, XSLX and PPTX files are all ZIP files!

Lots of files use ZIP compression as a container format. Renaming with a .zip extension breaks compatibility.

Slow Down Music - Where I commit thought crimes...

Freedom is the right to be wrong, not the right to do wrong. - John Diefenbaker

Renegade

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 13,288
  • Tell me something you don't know...
    • View Profile
    • Renegade Minds
    • Donate to Member
Re: Bizarre Firefox Behaviour
« Reply #4 on: March 16, 2011, 07:41 PM »
Anyways, reported it here.
Slow Down Music - Where I commit thought crimes...

Freedom is the right to be wrong, not the right to do wrong. - John Diefenbaker