What are selectors in jQuery and how many types of selectors are there?
Answer / 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 |
Explain "beforesend(xhr)" paremeter of jquery ajax method?
What are the types of selectors in jQuery?
How do I pull a native DOM element from a jQuery object?
What are the slow selectors in jquery? : jquery mobile
What is the advantage of using protocol less URL while referencing jQuery from CDNs?
Which sign is used as a shortcut for jQuery?
What is the use of jQuery load method?
What is the starting point of code execution in jquery?
Can you use any other name in place of $ (dollar sign) in jQuery?
What is the difference between $('div') and $('<div/>') in jQuery?
Why there are two different version of jQuery library?
How do you stop the currently-running animation?