You get "jquery is not defined" or "$ is not defined" error. What could be the reason?
Answer Posted / 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 |
Post New Answer View All Answers
How to check/uncheck an input in jquery?
Differentiate between width() vs css(‘width’) in jquery
Explain cdn? : jquery mobile
Mac, windows or linux? Why do you love this platform while using jquery?
How do you check or uncheck a checkbox input or radio button?
What is a jquery library?
Explain each() function in jquery?
How do you install/use jquery in a project. What is the minimum setup needed to start using jquery.
What is the use of html() method in jquery?
What is the minimum setup needed to start using jquery.
Explain .on()? : jquery mobile
How to get the server response from an ajax request using jquery?
How to use connect?
Have any of your startup projects failed dismally - if so, why and how did you learn from them?
How do you get the attribute of an html tag in jquery?