Preface, I have absolutely no experience with SharePoint (we use 2016) and I've received tasking that requires me to set some things up. Basically, my org wants to set up a stress test application on our home page. So I have this java script that's supposed to get most of it up and running. They've also provided me with a document that's supposed to walk me through the setup. I created a document library and uploaded the .js file and created a web-part page in the "full page, vertical" format. My documentation then says this:

o Click on the “Add a Web Part” link. A web part selector will appear under the SharePoint ribbon.

o In the left pane, choose “Media and Content”.

o In the middle pane, choose “Content Editor”.

o On the right side, click on the “Add” button.

o A new Content Editor web part should be visible. Click on the “Click here to add new content” link.

o In the ribbon, inside the “Format Text” tab, click on the “Edit Source” button.

o Here you will manually type a SCRIPT tag:

< script id="stress-meter" type="text/javascript" src="/sites/intranet/stressmeter/stressmeter.js"></script >

o Click “OK”.

o In the ribbon, click on the “Page” tab, and click on the “Stop Editing” button.

o Once you are out of page edit mode, the page will automatically render the initial setup

Well... The initial setup did not render, it's just a blank page with the words "content editor".

How should I proceed?

  • Check in "console" of browser's developer tools if there is any error. Also check if your javascript file is loaded or not in "Source" tab in developer tools. If file is not loaded properly try adding absolute/complete path of javascript file in script tag Apr 8, 2021 at 4:56
  • @GaneshSanap In my console I see "SEC7112: Script from [...] was blocked due to mime type mismatch". As for source tab, I don't have one of those...
    – Jack
    Apr 8, 2021 at 5:58

1 Answer 1


Try this:

  1. Create a .html file and add below code in it:
<script type="text/javascript" src="/sites/intranet/stressmeter/stressmeter.js"></script>
  1. Upload this file in SharePoint document library.
  2. Add content editor web part on page.
  3. Edit Web Part

enter image description here

  1. Add HTML file link in Content Link
  2. Click Apply
  3. In the ribbon, click on the "Page" tab, and click on the "Stop Editing" button.

enter image description here

Your Answer

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

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