Share via

Display/share a primitive web page via SharePoint

Anonymous
2022-10-22T14:12:00+00:00

I need to display/share a primitive single web page via SharePoint. The page consists of an HTML file and a folder with images and a few CSS files.  The page is updated regularly.

The page displays perfectly fine when the HTML file is simply dragged from Windows Explorer into any browser.

However, when opening the same *.HTML file from within my SharePoint library in a browser, all formatting lost and all images contained on the page are not displayed. The page looks like in this example of the Stack Exchange homepage (the page has simply been saved as web page from Chrome into a local OneDrive folder and then has been opened in SharePoint): 

Obviously SharePoint does not find the folder with the images and CSS files that are referenced in the HTML page.

What should I do to display the HTML file correctly as a web page in SharePoint?

Or is there another way to directly share a simple web page that is saved in my OneDrive?

Microsoft 365 and Office | SharePoint | For business | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

3 answers

Sort by: Most helpful
  1. Anonymous
    2022-10-25T10:29:44+00:00

    Hi DavidG4P,

    Thank you so much for posting back, expressing your requirement and sharing a Workaround. I am sure this will also help other community members experiencing the same issue. Let us use this Workaround as we wait on the Developers Team to fix this issue for us.

    Summary:

    Issue Description:

    =============

    Opening .HTML files from within SharePoint library in a browser loses all formatting and all images contained on the page are not displayed.

    =============

    Steps taken

    =============

    Submitted Feedback to Developers Team

    =============

    Workaround

    ============

    Save the files in the old DOC format. DOC files will be displayed everywhere in SharePoint and Teams without any problems.

    ============

    Once again, thanks for sharing with us this important information.

    Thanks for your kind understanding and patience. Stay safe!

    Sincerely,

    Edwine | Microsoft Community Moderator

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2022-10-24T19:24:54+00:00

    Hello Microsoft Support,

    thanks for the comprehensive information on this matter. So it seems that currently it is not possible to display HTML pages directly in SharePoint or Teams.

    But it is encouraging to see that this may already be being worked on.

    Our use case is that we create and maintain certain project documents in Word. We save these documents directly as HTML from Word into a SharePoint library, and would like to publish these HTML files via SharePoint and Teams.

    The files are changed several times a day, so we want to use the HTML file created by Word directly, without any further intermediate conversion steps.

    We have now found out that a workaround is to save the files in the old DOC format. DOC files are displayed everywhere in SharePoint and Teams without problems, and without starting the browser-version of Word right away.

    Thanks again for the support.

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2022-10-24T09:50:23+00:00

    Dear DavidG4P,

    We apologize for late reply! Thanks.

    I carefully went through your description, and I don't know how to reveal this. I'm afraid!

    I noticed that some other community members have already raised this issue, and I have added my vote. I am sure Developers are working on this. Please also add your votes so that the developers can give it a priority and fasten the process. You can vote via these links on SharePoint Feedback Portal: Allow Sharepoint to Open HTML pages in Browser · Community (microsoft.com) and Make HTML files display in the browser for SharePoint Online when clicked on just like ASPX files · Community (microsoft.com).

    Some community member mentioned that saving as PDF would work as a workaround for him!

    You could also go to Power Apps Community and post a new question and see if Engineers from that side can give ideas of apps that can use Flow to achieve this: Power Apps Community - Power Platform Community (microsoft.com) and Solved: Opening an html file directly in browser - Power Platform Community (microsoft.com).

    Thanks for your kind understanding and patience. Stay safe!

    Sincerely,

    Edwine | Microsoft Community Moderator

    Was this answer helpful?

    0 comments No comments