admin管理员组

文章数量:1392110

Here is my JsFiddle link. I'm testing that jQuery works, but it doesn't. Have I made any mistakes? I have checked documentation of jQuery and everything seems to be okay. What's wrong?

$(document).ready(function() {
    //insert code here
    alert("this will flre when the DOM is loaded.");
});

Here is my JsFiddle link. I'm testing that jQuery works, but it doesn't. Have I made any mistakes? I have checked documentation of jQuery and everything seems to be okay. What's wrong?

$(document).ready(function() {
    //insert code here
    alert("this will flre when the DOM is loaded.");
});
Share Improve this question edited Feb 4, 2021 at 18:06 Brian Tompsett - 汤莱恩 5,89372 gold badges61 silver badges133 bronze badges asked Apr 2, 2013 at 9:44 Filip BartuziFilip Bartuzi 5,9318 gold badges58 silver badges105 bronze badges 1
  • 4 You did not load the jQuery library. Look at the left panel. jsfiddle/cjFUf/7 – Antony Commented Apr 2, 2013 at 9:45
Add a ment  | 

4 Answers 4

Reset to default 4

Select the library first as given in the image below

Then you can call jQuery as below

$(document).ready(function(){
    alert("All is well");
});

Check out this live fiddle http://jsfiddle/mayooresan/TTu3C/

You need to choose the jQuery library on the left. It let jsFiddle know what kind of library or framework you want to load.

You need to include the JS file in the left top.

this will do.

Edit: Updated Version of JSFiddle supports "FRAMEWORKS & EXTENSIONS" under "JavaScipt" Section. There user may select JQuery Version.

I have included and updated fiddle.

Fiddle Link:http://jsfiddle/MarmeeK/cjFUf/51/

Or see the Image below for more clarity.

you forgot to load the library... on you left hand side of the fiddle.. you need to choose the framework you want to choose..in your case it is jquery

Frameworks & Extensions

working fiddle...

本文标签: javascriptjQuery doesn39t respond JSFiddleStack Overflow