Friday, May 11, 2007

[MOSS2007] Configure SharePoint 2007 to show the PDF icon [UPDATED]

To configure SharePoint 2007 to show the PDF icons with PDF documents, do the following:

  1. Download the pdf icon.
  2. Copy the image to C:\Program Files\Common Files\Microsoft Shared\Web server extensions\12\Template\Images
  3. Edit the docicon.xml in C:\Program Files\Common Files\Microsoft Shared\Web server extensions\12\Template\XML and add: <Mapping Key="pdf" Value="icpdf.gif" />
  4. Perform an IISReset.
  5. Voila, you are done!!

PDF Icon:

5 comments:

Jeroen Ritmeijer said...

Hi Yorick,

Not sure if your advice is based on a beta version of MOSS, but I had to correct the following in order to get it to work:

1. The XML tag uses a capital initial for Mapping, Key and Value.

2. The tag should be self closing.

3. The path is 'TEMPLATE', not 'TEMPLATES'.

Hoi,

Jeroen

Yorick said...

Jeroen,

Thanks for the correction, I changed my post. You are absolutely right.

I always copy a line and edit the filename.

Regards,

Yorick

Jeroen Ritmeijer said...

Hi Yorick,

I just keep ending up on this page, brilliant. Well, every time I install a SharePoint server that is.

Shameless plug, but the real reason I am so interested in PDF icons is because I have developed a PDF Converter for SharePoint.

http://www.muhimbi.com/Products/PDF-Converter-for-SharePoint.aspx

Jeroen

OBJimG said...

I added the icon and updated the XML file as directed following the additional suggestions. The icon works perfectly for me but the other domain users are promted with a log on screen and then when it fails the icon does not display. Are there special permissions that need to be put in the folder structure?

Yorick said...

This is caused by the fact that you probably have moved the file from a location on C drive (Temp folder for example) to the 12 hive. When you use move, the permissions are moved along with it. This usually means only admins have access to the file :-)

To solve this, force the folder permissions to the icon file.