1 <script src="https://code.jquery.com/jquery-3.1.1.min.js" integrity="sha384-3ceskX3iaEnIogmQchP8opvBy3Mi7Ce34nWjpBIwVTHfGYWQS9jwHDVRnpKKHJg7" crossorigin="anonymous"></script>
2
1<script src='jquery.js'></script>
2if (typeof $ == 'undefined') {
3 var $ = jQuery;
4}
5
1/Uncaught TypeError: $ is not a function
2
3// Usually this is because Jquery doenst know what $ is
4// because it isn't described
5
6jQuery(document).ready(function() {
7
8 // In the brackets you write your Code
9 // for each new function you start with
10
11 jQuery(window).scroll(function(){
12 // etc..
13 )};
14
15};
16// If you are testing on a localhost dont forget to embed the latest jQuery
17
1(function($){
2
3 $(document).ready(function(){
4 // write code here
5 });
6
7 // or also you can write jquery code like this
8
9 jQuery(document).ready(function(){
10 // write code here
11 });
12
13})(jQuery);
14