RBZ as allowed extension
-
@juantxo said:
Hello,
I have a problem with rbz file. In my web I have a rbz file to download but
windows 7 changes automatically the extension and users download zip file, not the real rbz.
You can see the problem in skelion.net. If you put mouse over download you can see the name of the file to download,
"skelion_v503.rbz" but afer download you have "skelion_v503.zip" not "skelion_v503.rbz".Someone knows something about this problem?
for what it's worth, i just downloaded the file at skelion.net and it came in as .rbz.. not .zip..
(OS X.7 / Safari)have you tried a different browser? or do you think it's the actual OS doing the changing?
-
I think is windows 7 but not sure. With chrome and with explorer in windows 7 extension is changed automatically.
In XP not. But I don't have windows 7, so I never saw this transformation. Some users with problems tell me about this. -
I suppose I'm the wrong person to discuss this as I know next to nothing about windows but maybe there's a right click option to download the file as it is on your site?
right click-> 'download linked file as...'
or something?
-
Does it happen some anywhere else but that site? It could be an issue with how the file is served from that server. I had problems with .gadget files being downloaded as .zip in Internet Explorer - but that was due to some HTTP headers not being right.
-
I'm not sure, I don't have windows 7, but its very weird this automatic extension change from ".rbz" to ".zip". It could be a security issue maybe.
-
Finally I couldn't solve the problem. Windows 7 changes extension of rbz to zip when user download from web page.
So I'm going to use zip file extension. I'm agree with Dan. I think is not necessary have two names for same extension. -
@juantxo said:
Finally I couldn't solve the problem. Windows 7 changes extension of rbz to zip when user download from web page.
So I'm going to use zip file extension. I'm agree with Dan. I think is not necessary have two names for same extension.Question is, does it happen just on skelion.net? I've never gotten a .rbz as .zip - but I didn't get around to test from skelion.net.
What happen if you download a .rbz from SCF? Try my attached file.
-
Sidenote - why does the download have a
random
URL argument?http://skelion.net/skelion_v503.zip?random=e46a3d22cf0dddbea0e1b1e1ffba494e
-
A friend with windows 7 help me to do some test and it seems random was the problem.
Now it downloads right..
(I used random because a friend told me I can use it to solve problems of browser cache but actually I don't need it so I erase it.)Thanks thomthom, I will use .rbz finally, but continue thinking two extension for the same is too much...
-
@juantxo said:
(I used random because a friend told me I can use it to solve problems of browser cache but actually I don't need it so I erase it.)
If caching is an issue then it's better to set the correct HTTP headers than adding random characters to the URL.
Here is an extract of a PHP script I use to serve plugins in either zip or rbz format:
<span class="syntaxdefault"><br /></span><span class="syntaxcomment">// fix for IE catching or PHP bug issue<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Pragma; public"</span><span class="syntaxkeyword">);<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Expires; 0"</span><span class="syntaxkeyword">);</span><span class="syntaxdefault"> </span><span class="syntaxcomment">// set expiration time<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Cache-Control; must-revalidate, post-check=0, pre-check=0"</span><span class="syntaxkeyword">);<br /></span><span class="syntaxcomment">// browser must download file from server instead of cache<br /><br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Cache-Control; private"</span><span class="syntaxkeyword">,</span><span class="syntaxdefault">false</span><span class="syntaxkeyword">);</span><span class="syntaxdefault"> </span><span class="syntaxcomment">// required for certain browsers<br /><br />// force download dialog<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Type; application/force-download"</span><span class="syntaxkeyword">);<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Type; application/octet-stream"</span><span class="syntaxkeyword">);<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Type; application/download"</span><span class="syntaxkeyword">);<br /><br /></span><span class="syntaxcomment">// use the Content-Disposition header to supply a recommended filename and<br />// force the browser to display the save dialog.<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Disposition; attachment; filename=\"$requested_filename\";"</span><span class="syntaxdefault"> </span><span class="syntaxkeyword">);<br /><br /></span><span class="syntaxcomment">/*<br /> The Content-transfer-encoding header should be binary, since the file will be read<br /> directly from the disk and the raw bytes passed to the downloading computer.<br /> The Content-length header is useful to set for downloads. The browser will be able to<br /> show a progress meter as a file downloads. The content-lenght can be determines by<br /> filesize function returns the size of a file.<br />*/<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Transfer-Encoding; binary"</span><span class="syntaxkeyword">);<br /></span><span class="syntaxdefault">header</span><span class="syntaxkeyword">(</span><span class="syntaxstring">"Content-Length; "</span><span class="syntaxkeyword">.</span><span class="syntaxdefault">filesize</span><span class="syntaxkeyword">(</span><span class="syntaxdefault">$real_file</span><span class="syntaxkeyword">));<br /></span><span class="syntaxdefault">readfile</span><span class="syntaxkeyword">(</span><span class="syntaxdefault">$real_file</span><span class="syntaxkeyword">);<br /></span><span class="syntaxdefault"> </span>
Advertisement