I'm on Sharepoint project for a client, and I took over the development of website, but the client has the lead of project. Based on a Bootstrap Theme, the project works on local. But, when I try on Sharepoint, jQuery and Components doesn't work. I use the Live Editor of Sharepoint for add my scripts and CSS in the footer. The code used, is the standard code of template, works locally.

Thank you for your help.

The Sharepoint code : http://snippi.com/s/9x5y663

This is my footer in Sharepoint

 <!-- Bootstrap Core CSS -->
    <link rel="stylesheet" href="/sites/cv/ambassadors/SiteAssets/css/bootstrap.min.css" type="text/css">

    <!-- Custom Fonts -->
    <link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'>
    <link href='http://fonts.googleapis.com/css?family=Merriweather:400,300,300italic,400italic,700,700italic,900,900italic' rel='stylesheet' type='text/css'>
    <link href='https://fonts.googleapis.com/css?family=Lato:400,700,900,300' rel='stylesheet' type='text/css'>

    <link rel="stylesheet" href="/sites/cv/ambassadors/SiteAssets/font-awesome/css/font-awesome.min.css" type="text/css">

    <!-- Plugin CSS -->
    <link rel="stylesheet" href="/sites/cv/ambassadors/SiteAssets/css/animate.min.css" type="text/css">

    <!-- Custom CSS -->
    <link rel="stylesheet" href="/sites/cv/ambassadors/SiteAssets/css/creative.css" type="text/css">
    <link rel="stylesheet" href="/sites/cv/ambassadors/SiteAssets/css/style-customOffice.css" type="text/css">

 <!-- jQuery -->
    <script src="/sites/cv/ambassadors/SiteAssets/js/jquery.js"></script>

    <!-- Bootstrap Core JavaScript -->
    <script src="/sites/cv/ambassadors/SiteAssets/js/bootstrap.min.js"></script>

    <!-- Plugin JavaScript -->
    <script src="/sites/cv/ambassadors/SiteAssets/js/jquery.easing.min.js"></script>
    <script src="/sites/cv/ambassadors/SiteAssets/js/jquery.fittext.js"></script>
    <script src="/sites/cv/ambassadors/SiteAssets/js/wow.min.js"></script>

    <!-- Custom Theme JavaScript -->
    <script src="/sites/cv/ambassadors/SiteAssets/js/creative.js"></script>

I have an error when I click on anchor for scroll. But I think this error is caused by jQuery doesn't execute.

Uncaught Error: Syntax error, unrecognized expression: /sites/cv/ambassadors/SitePages/Community%20Home.aspx#onGoing
  • do you mean locally as in without SharePoint, or within SharePoint on your own environment? Are you using SharePoint Designer to edit the markup of these pages, or are you just copying and pasting this code inside of a SharePoint page? How does SharePoint interact with this, through a webpart page, homepage, template, custom form?
    – Mike
    Apr 6, 2016 at 15:50
  • Can you show the javascript function that should do the scrolling? Apr 6, 2016 at 17:23

1 Answer 1


If I take a guess I would say your local links only link to anchors (#) in the href attribute. Whereas the sharepoint links have a path containing / in the href attribute.

This is fixed by changing the code in your onclick event handler to only use the part after the # to find the scrolling target element.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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