[OSM-talk] Announce: new version of Validator plugin

David Earl david at frankieandshadow.com
Mon May 28 18:21:36 BST 2007



> -----Original Message-----
> From: Francisco R. Santos [mailto:frsantos at gmail.com]
> Sent: 28 May 2007 17:52
> To: David Earl
> Cc: Talk Openstreetmap
> Subject: Re: [OSM-talk] Announce: new version of Validator plugin
>
>
>
>
>
> On 5/28/07, David Earl <david at frankieandshadow.com> wrote:
>
> I hadn't used this before because when I tried to download it all
> I got was
> a zip file. Then I vaguely remembered that jar files were in fact just zip
> files with a different suffix, so I changed it and it worked. Is there a
> reason why it isn't .jar?
>
> it *is* a .jar. Maybe a browser problem?


I'e investigated this a bit more. Sure enough, firefox sees it as a jar
archive. But IE(7) sees it as a .zip. Yet IE7 correctly sees UtilsPlugin.jar
as a jar

If I use curl to compare to compare the headers for UtilsPlugin.jar and
validator.jar I see that the formers says
  Content-Type: application/x-java-archive
while validator.jar says
  Content-Type: text/plain

I rather think that in the absence of a useful Content-Type, IE7 looks at
the magic number at the start of the file and (since it really is) guesses
it is a zip, while maybe Firefox is maybe using the suffix on the URL.

I think it is the text/plain that is causing the problem: the browsers are
having to guess at the content, and it isn't really possible to tell the
different between a jar and zip. If you have a Filename with your
Content-Type, I think IE7 would be OK as well.

I don't think IE7 is wrong here; it's just that there isn't enough
information in the header.

David





More information about the talk mailing list