You get "jquery is not defined" or "$ is not defined" error. What could be the reason?
Answer / chaitanya
There could be many reasons for this.
You have forgot to include the reference of jQuery library and trying to access jQuery.
You have include the reference of the jQuery file, but it is after your jQuery code.
The order of the scripts is not correct. For example, if you are using any jQuery plugin and you have placed the reference of the plugin js before the jQuery library then you will face this error.
Find out more here.
| Is This Answer Correct ? | 1 Yes | 0 No |
What is jquery selectors? Give some examples.
How we can get the input value of an element using jquery?
Explain .live()? : jquery mobile
What are jquery plugins?
Differentiate between width() vs css(‘width’) in jquery
Name some of the methods of jquery used to provide effects?
Tell me which program is useful for testing jquery?
Is vanilla js faster than jquery?
Explain url paremeter of jquery ajax method?
Which one is more efficient, document.getelementbyid( "idname") or $("#idname)?
Suppose if you have a server control(asp.net server control, button) and on the click of button you want to call a jquery function, so tell me how you will call a jquery function without postback?
What is difference between onload and ready?