Home › Forums › Spoodoo Scripts › StickyHeaders › Sticky Headers not working
- This topic has 7 replies, 3 voices, and was last updated 2 years, 5 months ago by
And.
-
AuthorPosts
-
Devi
GuestHi…
I have downloaded the js file from your website and saved in the sharepoint library and used that link in the content query web part. And this is not working. could you please help me on my next steps
Daniel
KeymasterHi Devi,
are you sure you mean Content Query Webpart?
Here are two approaches:
Content Editor Webpart
1. First create a HTML file with the following content:
<script type=”text/javascript” src=”/path/to/stickyHeaders.js”></script> (adjust the path)2. Upload this file to SharePoint
3. Add a content Editor Webpart to your page and edit the webpart

4. Put the path to the HTML file into the Content Link field:

5. Apply the changes, save the page
Script Editor Webpart
1. Add a Script Editor Webpart to your page
2. Edit the Webpart and click the EDIT SNIPPET button
3. Add the script tag (adjust the path), click Insert and save the page

And please don’t forget to add jQuery to your page.
Daniel
Ricardo F
GuestDaniel,
sorry noobie here, what do you mean by not forgetting to add jQuery to the page?
Ricardo F
Guestsorry, I got it, it’s the js code you are providing inside the js file.
DCH
GuestOr, as I have done, add the script reference to your master page so it is automatically applied to every list view, even on admin screens like the List Settings.
Rahman
GuestI have a Problem with this great script.
Its working fine … unless I stay on the page.
As soon as I left the page and come back, the script doesn’t working anymore.
Derek Drake
ParticipantI have added the js script to my Asset Library and am using the CEWP to reference the js file but the only thing happening is it is literally displaying contents of the script.
And
GuestI would need some help… I really don’t know anything about HTML, which is the reason I’m here :)
I would love to have the sticky headers working but so far I got no results.
I have uploaded the JS file in a folder (AndJS) and then I created a Script Editor webpart with the following content:
<script src=”/sites/And/SiteAssets/AndJS/stickyHeaders_3.2.0.js” type=”text/javascript”></script>
then I have added an HTML file with the following content (I have tried putting the jquery reference to in the HEAD part too, same results):
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”><head>
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
<title>Untitled 1</title></head>
<body>
<script src=”http://and/sites/and/SiteAssets/jquery-3.3.1.min.js” type=”text/javascript”></script>
</body></html>
At last, I have added a Content Editor Webpart with the following link:
/sites/and/SiteAssets/StickyH.html
Any hint on what I am missing? Many thanks!
-
AuthorPosts