TITLE
    Personal Web Sharing: Setting MIME Type For PDF Files
Article ID:
Created:
Modified:
24363
2/12/98
2/12/98

TOPIC

    I have Personal Web Sharing 1.1 which came with Mac OS 8. I want to put Adobe Acrobat PDF files in my web folder so that users with the Acrobat plug-in can view PDFs directly in their browser. Every time I try to view one of these files with my web browser, however, the browser tells me it is a Postscript file and won't view it with the plug-in. Then my only option is to save the file to my hard drive. How can I view the file using Adobe's plug-in?


DISCUSSION

    For a browser plug-in to work properly, both the client and the server have to be properly configured.

    The relevant information on the server in this case is the MIME type. A web server gives a browser a brief description of the data it is sending: whether it is text, a PDF document, a QuickTime Movie, or whatever. With Personal Web sharing 1.1, the default definition for PDF files is Postscript. Here's how to change this:

    Step One
    Open the Web Sharing Folder (this is in the Preferences folder, which is in the System Folder).

    Step Two
    Open the file named Web Sharing MIME Types.

    Step Three
    In the file, replace this line:

    pdf * * application postscript

    with these two lines:

    pdf * * application pdf
    * CARO PDF application pdf

    Step Four
    Save the changes to the file and close the file.

    Step Five
    Stop and restart the web server.

    The web server will now send the correct information to the browser if the file the user access is one of the following: (1) any file whose name ends with .pdf, or (2) any file which is an actual Adobe Acrobat PDF file, regardless of the name.

    Provided the browser is set up to use the plug in correctly, you should now be able to view the PDF using the plug-in. For any other browser plug-in, the procedure is the same, you just need to obtain the MIME type information from the plug-in vendor.


Document Information
Product Area: Mac OS System Software
Category: General OS
Sub Category: General Topics

Copyright © 2000 Apple Computer, Inc. All rights reserved.