| |
MagerValp
Registered: Dec 2001 Posts: 1065 |
Content types and Firefox
Firefox recently got stricter about Content-Type:s, so it's no longer to automatically launch x64 or The Unarchiver from downloads on CSDB. Everything is sent out as application/octet-stream, and saving is the only option. Is there any chance we could get proper Content-Type:s for zip files, d64s, etc?
|
|
... 10 posts hidden. Click here to view all posts.... |
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
Quoting GroepazQuote:which is why you tell your browser to use x64 to open those types.
thats pretty much what i did ... unless people start using whatever fucked up file extension, where is the problem? :)
cause the "new" (its far from new) type application/x-d64 will work for everybody and application/octet-stream does not. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11293 |
whatever.... now go and fix that damned file listing =D |
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
only if you get Perff to fix the mimetypes on here ;)
hah! |
| |
chatGPZ
Registered: Dec 2001 Posts: 11293 |
PEEEEEEEEEERFFFFFF HELP!!!!!!!!!!!!! THIS IS URGENT !!!!!!!!!!!!!
=D |
| |
MagerValp
Registered: Dec 2001 Posts: 1065 |
Quote: i can view/open files directly fine, in firefox and in opera... what am i doing wrong? =P
And you're using FF3.6, not 3.5?
URL:s with Content-Type: application/octet-stream and Content-Disposition: attachment are *supposed* to force a save dialog...
As for CSDB, a few application/x-foo based on the file extension for the common C64 file types should suffice, and finfo_file() will mop up the rest.
d64: application/x-d64 (and d71, d81, etc)
prg: application/x-prg
sid: audio/prs.sid (IANA registered! :)
...and what else? Do we have VICE snapshots?
I guess the only tricky bit is how to handle .gz - as Content-encoding: gzip, or as application/x-gzip?
|
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
yay, another one with a clue ;)
gzip is no question, its application/x-gzip. you use content-encoding: gzip (or deflate) for compression on text/html and such.
so, perff will see dramatic performance increase if he starts using mod_deflate or mod_gzip.
but anyway, hope its clear now |
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
PS: groepaz, check SH. |
| |
MagerValp
Registered: Dec 2001 Posts: 1065 |
Well a case could be made for .prg.gz to be sent with Content-encoding, but application/x-gzip is probably better. |
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
Quoting MagerValpWell a case could be made for .prg.gz to be sent with Content-encoding, but application/x-gzip is probably better.
to be totally accurate, you could make a ".prg" (and d64,t64,etc) get transferred with Content-encoding: gzip (or deflate). Which means the server and the browser will do the g(un)zipping on the fly. Doing it for ".prg.gz" would mean gzipping it twice...
anyway, I'll write up some simple apache conf for it. |
| |
Burglar
Registered: Dec 2004 Posts: 1069 |
erm, first of all, start using an alive apache version, like 2.2.15
compile it with --enable-deflate, or if you use a standard distribution
it's probably already enabled.
### mime.types
application/x-d64 d64
application/x-t64 t64
application/x-prg prg
audio/prs.sid sid
application/zip zip
the last 2 should already be there
### httpd.conf
TypesConfig /path/to/mime.types
AddOutputFilterByType DEFLATE text/html text/plain text/xml application/xml
AddOutputFilterByType DEFLATE application/javascript text/css
AddOutputFilterByType DEFLATE audio/prs.sid application/x-d64 application/x-prg
AddOutputFilterByType DEFLATE application/x-t64
and thats it
|
Previous - 1 | 2 - Next |