Forum Discussion
Crazy ASPX page behavior in Sharepoint Online document library , getting downloaded
tapansam Unfortunately, I don't believe this is the whole story as I am a member of the Owners group of a site but still cannot get aspx to run. I believe that the site must allow scripts to run, also. Here's a SO post that goes into it a little: https://sharepoint.stackexchange.com/questions/237928/how-do-i-allow-the-documents-library-in-an-office-365-group-site-allow-aspx-page
SPWade In fact, let me just follow up on this a little more. Unless you have Allow Custom Scripts turned on / enabled for your site you are only going to be able to create a new aspx page via the UI (or Designer) and that page will only be allowed to run certain web parts on it. Once you try editing the page and putting any custom script on it (or just editing what's already there and adding a simple space, then saving), it will break. Even the Page Viewer webpart is not going to work for viewing, say, an HTML page or a 3rd party page without custom scripts enabled.
Obviously, this is a security lockdown because someone with editor access to a page could put in some hidden script that acts on behalf of the user to, say, post some of their information to a list or activate a workflow.
The only alternatives I can see are a) enable custom scripts, b) put your customizations into an Add-In (App) and publish them to the SP store so they are trusted, c) redirect the user away from SP to an external system that hosts the content (and optionally use the SP API to interact with data - again, sorta the App approach without the overhead of dealing with, say, SP admins), or even d) have the user sync a folder with the content down to their local system and launch the content from there. Again, that's just another variation on external hosting. And is probably a nightmare to support.
Or, e) find a new environment to work in where you don't have all the ridiculous restrictions and vulnerabilities (worldwide MSFT outages, anyone?) of SP. 5000 item list limits - from 1998 - and explaining why they are ridiculous to SP admins is so fun and productive!