What are selectors in jQuery and how many types of selectors are there?
Answer Posted / chaitanya
To work with an element on the web page, first we need to find them. To find the html element in jQuery we use selectors. There are many types of selectors but basic selectors are:
Name: Selects all elements which match with the given element Name.
#ID: Selects a single element which matches with the given ID
.Class: Selects all elements which match with the given Class.
Universal (*): Selects all elements available in a DOM.
Multiple Elements E, F, G: Selects the combined results of all the specified selectors E, F or G.
Attribute Selector: Select elements based on its attribute value.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How can related code be encapsulated?
What is the advantage of using the minified version of jquery rather than using the conventional one?
What is the starting point of code execution in jquery?
What are the basic selectors in jQuery?
Explain some features of jquery knockout?
Explain each() function in jquery?
Is it possible that jquery html work for both html and xml document?
What is the difference between onload() and document.ready() function used in jquery?
What is the difference between onload() and document.ready()?
What were the biggest challenges of getting the 1.7 release out there?
How to multiple version of jQuery?
Mention some advantages of jquery.
How to prevent Right Click option using jquery?
How can you get the type of arguments passed to a function?
Explain cache paremeter of jquery ajax method?