0

you know if it´s posible put a index.html file as default page of a Sharepoint hosted app instead a Default.aspx page?

Any examples?

Thanks in advance

2 Answers 2

0

Try to make your index.html as default page in appmanisfest file. Change the startpage url in xml like ~AppWebUrl/Pages/index.html

But make sure you need to create index.html page and have to upload it in Pages library.

4
  • this is de problem. ichange the parameters in appmanifest and I deployed de app and when a try to launch de app, it says me that the index.html page not found. It's necesary to upload the page to sites pages library?
    – Ikatz
    Sep 22, 2014 at 11:50
  • Right click on your Pages module in Solution in Visual Studio>> Add html file there >> set that html file as a startpage url in appmanifestfile >> It should work like a charm!
    – ateet
    Sep 22, 2014 at 12:00
  • Thanks! maybe is because i changed de solution deleting a default.aspx and putting index.html, and the feature is not updated. The error is a feature deployment error.
    – Ikatz
    Sep 22, 2014 at 12:41
  • SharePoint won't let you to render an HTML page. The browser will want you to download it. Rename your .HTML to .ASPX. It will be the same HTML file, but SharePoint will actually render it. Feb 22, 2018 at 3:20
0

Assuming you are using Visual Studio 2017, right click on the Pages folder in the solution and select "Add" and then "New item". Choose to add an HTML file and pick any name, such as "index.html". Next, open the AppManifest.xml file. On the General tab, there is a field named "Start page". Set this to the HTML page you just created.

While supported, using an HTML file means you are responsible for bringing in the SharePoint chrome and other SharePoint web styles that you may want. Some of that is wired up already in the Default.aspx page.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.