About Me

I am a Software Engineer presently working in Microsoft as vendor.The main aim of this blog is to Share my knowledge in Sharepoint,AZURE and Silverlight.

Wednesday 30 December 2009

Opening HTML Files in Sharepoint 2010

I recently faced an issue where the customer was attempting to open HTML documents from a document library. He only had an option to download the document. He wanted the ability to open the HTML document directly within the browser.

By default, Sharepoint 2010 is blocking the ability to open HTML documents directly from a document library.

However this can be changed by adjusting the browser file handling option. The option is located here:


1. Central Admin\Application Management\Manage Web Applications.
2. Select General Settings for the specified web application
3. For Browser file handling, select permissive. The default is strict​

17 comments:

Nebulous Knight said...

Genius! I ha the same issue, but trying to open flash (swf) files, and couldn't do it. This solved my problem too, thanks very much!

Suyog Mahindrakar said...

Hi
I have same Problem. But i want to open html page inside the iframe.of my page how i can do that


Thanks in Advance.

Anonymous said...

GREAT! Thank you, you saved me hours!

sacchit said...

Thanks this works for swf files as well!!!

Cory said...

Thank you! Lifesaver. :)

Navi said...

Thanks a lot, I had a same problem, Now every thing is fine :)

Anonymous said...

Hi:

There is a better way to handle "Browser File Handle" issue. Take a look at my blog here: http://www.pdfsharepoint.com/sharepoint-2010-and-pdf-integration-series-part-1/

Solution #2 addresses Pdf extension without exposing entire Web Application to "Permissive" browsing. Setting "Browsing File Handle" to "permissive" opens too many vulnerabilities with other file extensions.

Thanks,

Dmitry

Herschel said...

I agree with Dmitry and modify the DocIcon.xml file

Vinayak said...

Hi,

Good Post. But, I have a different scenario, where i need to upload the ".shtml" files inside the document library and open them.

Bydefault ".shtml" files are blocked but i have removed the "shtm & shtml" extension from blocked files.

Now, the only problem is, I cant open shtml files in the browsers. It shows HTTP 404 Not Found error.
But, if i change the extension of file from SHTML to HTML. It Works..

What could be the Reason ?

Lê Trung Tín said...

Hi
Thanks you, you saved me proplem!

trungtin8x@gmail.com

Srikanth Gadiyaram said...

Hi I need to import html pages content to sharepoint 2010 and need to have sharepoint look and feel to those pages, and i have 70,000 pages to convert. CAN YOU PLEASE SUGGEST ME ANY SIMPLE SOLUTION?????

Anirudh Kulkarni said...

awesome!!

Is this thing turned on ? said...

I see Dmitry's point, however, for sites within a corporate intranet ( for instance a TFS Portal ), having the "strict" setting for things such as a the process guidance is ridiculous.

There should be a way without resorting to scripts to selecting say "I want to view this file in the browser window within Visual Studio". It shouldn't be this convoluted.

DoNnIe said...

is there a way to open a Word file preview without downloading and without the possibility to change it?

Helpmate said...

Thanks its very helpful

Unknown said...

Thank you for tip. Worked for us.

nikkolayebba said...

WONDERFUL Post.thanks for share..extra wait .. … online casino