How Browsers (IE) understand file types.

R

Roberto

1) I have the following html code on the server:

<HTML>
....
.....
<BODY>
<A HREF = http://MyServer/MyDoc.doc> Click here to see the document</A>

When I click on the link How Internet Explorer understand that it's a Word
Document and It's necessary open it with Microsoft Word ? Is The extension
to give the necessary information to Internet Explorer ?
Where does IE look for the application to use to open the file on the server
? On the local registry ?
I have tried to rename Mydoc.doc in MyDoc.pdf and I have called

http://MyServer/MyDoc.pdf and the browser has opened Acrobat Reader but the
binary format is for Microsoft Word.

Does the Browser User an Http_Header sended automatically ? (for example
HTTP_FILE_NAME....IF IT EXISTS)

2)Now I have the following link:

http://MyServer/ReturnMyDoc.asp

It returns the binary data of MyDoc.doc file. Now I want to say to the
browser that the file is called MyDoc.doc (I don't want to use Content Type
= ms-application/msword) : is there a header to say this to Internet
Explorer ?

Thanks Rob.
 
M

Mark Schupp

The association is in the client system registry. Usually set up when you
install the application that is intended to view the document. look at .pdf
and AcroExch.Document under hkey_classes_root for an example.
 
M

Mike Moore [MSFT]

Hi Rob,

Thank you Mark for your info. I thought I might expand on it a bit.

1)
IE knows which application to run based on the file's file extension (.doc
or .pdf) along with the content type (ms-application/msword). IE matches
these up with the local registry to determine which application to launch.

2)
Here the file extension is .asp. That means the content type must be used
for IE to distinguish what application to launch. You wrote that you don't
want to use content type either. That means IE will not know which
application to launch.

Thank you, Mike
Microsoft, ASP.NET Support Professional

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward
steps listed to improve your computer’s security.

This posting is provided "AS IS", with no warranties, and confers no rights.


--------------------
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top