On Saturday 09 November 2002 21:33, Miles Elam wrote: > Antonio A. Gallardo Rivera wrote: > >Kjetil Kjernsmo dijo: > >>On Thursday 07 November 2002 23:57, Tony Collen wrote: > >>>However, later I realize that using file extensions is "bad". > >>> Read http://www.alistapart.com/stories/slashforward/ for more > >>> info on this idea. > > > >I know about that. The theory is fine, but in the real world... Are > > you tried to open a PDF file without the .pdf extension with MS IE > > 6.0 SP1?
No, I have barely touched IE since 3.0. > > It does not work. MS IE relays mainly on the extension of > > the file to open a pdf file. What?!? What you're saying is that IE is ignoring the content-type? That's just incredibly silly... > How we can address this? I already > > know that Carsten and Mathew in his book dont recommend the use of > > extension and I agree. But how we can tell MS Internet Explorer > > about that? > > PDF isn't IE's normal method of receiving information (ease of use > with Acrobat aside). If you specifically want the PDF > representation, specify *.pdf. If what you want is the resource, > then you aren't asking specifically for PDF. If all you have is PDF > and PDF is the only representation, then having your URL specify that > you are serving PDF hurts no one and corrupts no URLs. Yes it does! What representation is chosen should only depend on the Accept header, and what the UA should do with a file it receives should have nothing to do with the filename whatsoever, it should be based on the Content-Type-header in the response, solely. It's been a while since I read the HTTP 1.1 spec, but IIRC, it is pretty clearly spelled out there. It should only depend on the MIME-type. On the server and client sides, separately, how it is done is of no concern of anybody, but that the client depends on what file extension the server uses has to be a violation of the spec, again IIRC. During content negotation, an extensionless URL should be responded to with 200 if the server has a representation which is acceptable according to the client's Accept*-headers, with a Location-header saying where to find the best file, and that file may well have a .pdf extension. If no appropriate representation is found, the server should respond with 406. </rant> Cheers, Kjetil -- Kjetil Kjernsmo Astrophysicist/IT Consultant/Skeptic/Ski-orienteer/Orienteer/Mountaineer [EMAIL PROTECTED] [EMAIL PROTECTED] [EMAIL PROTECTED] Homepage: http://www.kjetil.kjernsmo.net/ --------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>