-2

There is a site wide change that I cannot figure out the root cause of. I am getting the following errors on every page in the site collection: enter image description here

Upon inspection of the error taking place at "ProjectDashboard.aspx:544", I found the error occurs in the navigation bar (the ".tapForFlyout" is what starts the error): enter image description here

I am not sure how this error was introduced, nor how to fix it. I am using sharepoint online.

Edit: I have looked through the master page and there are no scriptLinks that aren't default. We don't have any add-ins that would cause this either. I asked my boss and the only thing changed was adding a custom CSS to the StyleLibrary/Themable folder.

3
  • Random javascript? You are calling for external JS script and you have no idea how they got there?? The error doesn't come from the html... but from a function called in one of those scripts that doesn't seem to work. Maybe you are running an incompatible jquery or bootstrap version.
    – Yugo
    Commented Jan 11, 2017 at 20:59
  • My boss made changes without explaining what he did... I don't know where the changes could be that would cause this Commented Jan 11, 2017 at 21:18
  • If your site has an https endpoint, then perhaps there is something wrong with the certificate or the local time on the server. If your site does not have an http endpoint, you should change the protocol to http for those jquery references. Commented Jan 11, 2017 at 21:48

2 Answers 2

1

From your error log, it seems like your external JavaScript reference are broken. My best guess would be that, you're referencing the two external urls (jQuery and Bootstrap) using Protocol-relative URL (//).

For some reason, SharePoint master page doesn't like protocol-relative URL so replace your first two external JavaScript references to begin with 'https://' instead of '//'.

In your master page, replace

<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js"></script>
<script type="text/javascript" src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>

With

<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js"></script>
<script type="text/javascript" src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
1
  • You should probably speak with your boss first and foremost, he may have installed a theme for Sharepoint, which is Bootstrap. jquery is a set of instructions for working with html manipulation, a requirement to use Bootstrap. As stated t's not correctly called, so it's unable to run the tapForFlyout function because the script is unable to load.
    – Yugo
    Commented Jan 12, 2017 at 0:34
0

The error is informing you that the function tapForFlyout is not defined within the javascript library tapflyout.js

Sorry I can't add any more information than that as it looks like your custom js library has been broken.

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.