1

I am new for here and sharepoint. I would like to ask a question regarding Javascript for Sharepoint page. I am sorry if it was asked before.

I have found a script which is called "let-it-snow.min.js". I have added it to SiteAssets. Also I have added "jquery-3.2.1"to same location. As far as I read from the web site, I would be able to snow to my sharepoint webpage..

enter image description here

After that I have created a script editor on Master Page and I have added the below script code to call the files.

<script src="../SiteAssets/jquery-3.2.1.js"></script>
<script src="../SiteAssets/let-it-snow.min.js"></script>

I have also set the Chrome Type to "None". When I save the script which is on the Master Page. Anything happened unfortunately. I guess I did something wrong & there is still missing configuration on the script.

Is there anyone who can help me regarding the problem?

Thanks in advance, -Burak

3 Answers 3

0

Remove “..” from the path to the js scripts.

Just reference as /SiteAssets.

0

first of all i want to tell you ".." means you are trying to go one level up wherever you are.

"/" means you are in root url

"/sites/yoursitename/SiteAssets/let-it-snow.min.js" or "/SiteAssets/let-it-snow.min.js" if you are in root site. please let me know in case of any problem.

8
  • Hi Negi,Thank you very much for your message. I didn't know the meaning of "..". I have fixed it as you mentioned as below, <script src="/sites/SRTAC/SiteAssets/jquery-3.2.1.js"></script> <script src="/sites/SRTAC/SiteAssets/let-it-snow.min.js"></script> and <script src="/SiteAssets/jquery-3.2.1.js"></script> <script src="/SiteAssets/let-it-snow.min.js"></script> But unfortunately the both types of script aren't working :/ Dec 13, 2017 at 13:22
  • Hi Burak, can you please check you all files is checked in ?
    – Negi Rox
    Dec 13, 2017 at 13:29
  • another option please type full url in src. and hit same url in browser and check it is accessible by another user or not?
    – Negi Rox
    Dec 13, 2017 at 13:30
  • Hi, Yes the both files are checked in before.. If you would like to check the files, I can provide it to you by some way.. Dec 13, 2017 at 13:54
  • yes burak please provide i will check in ma end will let you know
    – Negi Rox
    Dec 13, 2017 at 14:16
0

In Browser developer tool,please check if the Js file referenced has been loaded in the page like below: enter image description here

And is there any error message in Console ?

Your Answer

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

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