1

JavaScript isn't my strongest skill, but I'll do my best to explain, so here it goes. I had someone create a slideup menu on my website and im also using jplayer music player.

Now everything works fine until I add this script at the top. For some reason it stops the slideup from working. This is the script that stops the slideup.

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>

If someone could tell me what im doing wrong that would be great.

3
  • 1
    Do you see any errors in the console? Commented Dec 9, 2013 at 14:56
  • Do you already have a jquery reference in your code that your menu uses? If you do, then you might have a version mismatch. You only need one jquery reference, and adding two of different versions can cause problems. Check your code for jquery references, and check your console. Commented Dec 9, 2013 at 14:59
  • It worries me that you are using different kind of apostrophes while JavaScript only accepts single apostrophe (') and double quotation mark (") Commented Dec 9, 2013 at 15:01

2 Answers 2

1

Try using this to include your jQuery: <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>

That is taken from the jplayer demo page at http://www.jplayer.org/latest/demo-01-video/ - line 22

Sign up to request clarification or add additional context in comments.

4 Comments

Yes! Maybe it resolves the issue. Just use: <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
Will you post your site's domain? Without that its just guesswork
does this help? im getting this error: TypeError: jq(...).jqEasyPanel is not a function
If your site isn't live, or you don't want to put your site live, just use a demo.mysite.com
0

you are not importing jQuery correctly. After consulting Google HOsted Libraries page (https://developers.google.com/speed/libraries/devguide?hl=es&csw=1#jquery) seems that the version to be imported should be 1.7.0 (Three digits, not two), try it!

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js"></script>

6 Comments

Just copy paste the link in the OP's code into your browser to see if it works, and loh and behold, it does.
Ouch! If you open the JS conosle (F12 > Console) Do you see any error?
Im getting this TypeError: jq(...).jqEasyPanel is not a function
Are you using this plugin? jqeasy.com If yes, I downloaded the code and I checked that it is running with jQuery 1.4.2 (a bit old) Probably you have a jQuery version conflict. How are you importing this library??
Anyway, I recommend you to use other jQuery library for the slider... Just typing "jQuery slider" in Google there are lots of them
|

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.