Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Mar 2012
    Posts
    18
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Trying to get Jquery scroll working / installing the jquery library

    Hi, this is my first ever post and i'm very new to coding so i hope i can explain this properly.

    I want to create a website similar to www.facepark.org, i'm aware this one was built in flash but my teacher said it should be possible to make using jquery.

    I found a website with the code that i need to allow the user to scroll around the website but as far as i can understand it to allow this code to work you have to install the jquery library first.

    So i have downloaded the jquery library from jquery.com and the put this download into my website folder.

    I then read on the site that i should write this:

    Code:
    <script type="text/javascript" src="jquery-1.7.1/jquery.min.js"></script>
    </head>
    to make it look for the library.

    Now in dreamweaver the jquery.min.js appears in a seperate tab to the rest of my source code and when i click on it it says jquery.min.js is not on the local disk and when i click 'get' it says that its not in the defined site.

    I've tried to research to find out what i'm doing wrong but i can't find it anywhere and i'm very confused. I hope i've managed to explain this so it makes sense!

    I'd be extremely grateful if anyone could offer any advice or even give me an idea of where to look for help!

    Thank you

    Hannah
    Last edited by VIPStephan; 03-26-2012 at 09:19 PM. Reason: fixed code BB tag

  • #2
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,636
    Thanks
    6
    Thanked 1,003 Times in 976 Posts
    Make sure the file path to the jQuery file is correct. According to the code you posted, a file called “jquery.min.js” needs to be in the directory “jquery-1.7.1”. This doesn’t sound like the usual set-up, though. How is your jQuery file called and where have you stored it (in relation to the HTML file)?

  • Users who have thanked VIPStephan for this post:

    HannahS (03-27-2012)

  • #3
    New Coder
    Join Date
    Mar 2012
    Posts
    18
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Hi thank you for replying,

    My jquery file is called jquery.min.js and it is saved in the same folder where my html files is saved. This is a folder that dreamweaver automatically created and is called unnamed site 2 and is just saved to my desktop.

    I've now changed the code so that it reads:

    [CODE] <script type="text/javascript" src="jquery.min.js"></script>
    </head> [CODE]

    So this should mean that its looking in the right place shouldn't it?

    The same thing problem is still happening though.

  • #4
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,636
    Thanks
    6
    Thanked 1,003 Times in 976 Posts
    If the HTML file and the JS file are in the same directory/on the same level then it should actually load it. Try this: Preview the HTML file in a browser of your choice and then in the address bar replace the HTML file’s name by the JS file name. It should show the JS file in the browser. If it does then the error is somewhere else. The error console that’s built into most browsers should also be able to give some info.

    It would help if you would put your site online somewhere and show us a link so we can check it out ourselves.

    And P. S.: If you post code then do it as in HTML, close the tags properly. It must read [CODE][/CODE] (with the slash in the closing tag).

  • Users who have thanked VIPStephan for this post:

    HannahS (03-26-2012)

  • #5
    New Coder
    Join Date
    Mar 2012
    Posts
    18
    Thanks
    3
    Thanked 0 Times in 0 Posts
    I've got it working now, by previewing it i could see that some of the files were in the wrong place. Thank you so much for your help and i will remember your tips for the next time i post.

    Thank you!

    Hannah


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •