Jquery Mock Test
Jquery Mock Test
This section presents you various set of Mock Tests related to jQuery Framework. You can
download these sample mock tests at your local machine and solve offline at your convenience.
Every mock test is supplied with a mock test key to let you verify the final score and grade yourself.
A - A jQuery Selector is a function which makes use of expressions to find out matching elements
from a DOM based on the given criteria.
B - jQuery selectors are used to select one or more HTML elements using jQuery.
C - jQuery selectors start with the dollar sign and parentheses - $()
Q 2 - Which of the following jQuery selector selects elements with the given element
tag-name?
A - $('tag-name')
B - $('#tag-name')
C - $('.tag-name')
Q 3 - Which of the following jQuery selector selects element with the given element id
some-id?
A - $('some-id')
B - $('#some-id')
C - $('.some-id')
Q 4 - Which of the following jQuery selector select elements whose css class is some-
class?
A - $('some-class')
B - $('#some-class')
C - $('.some-class')
Q 5 - Which of the following jQuery selector selects all elements available in a DOM?
A - $('*')
B - $('?')
C - $('#')
A - attr
B - getAttr
C - getAttributes
A - attrname, value
B - setAttrname, value
C - setAttributesname, value
A - addStyleclasses
B - addClassclasses
C - addCSSClassclasses
Q 9 - Which of the following jQuery method removes an attribute from each of the
matched elements?
A - deleteAttrname
B - removeAttrname
C - removeAttributename
A - hasCSSClassclass
B - hasStyleClassclass
C - hasClassclass
Q 11 - Which of the following jQuery method remove all or the specified classes from
the set of matched elements?
A - removeClassclass
B - removeStyleClassclass
C - removeCSSClassclass
Q 12 - Which of the following jQuery method adds the specified class if it is not
present, remove the specified class if it is present?
A - toggleStyleClassclass
B - toggleClassclass
C - toggleCSSClassclass
Q 13 - Which of the following jQuery method gets the html contents innerHTML of the
first matched element?
A - html
B - getHtml
C - getInnerHtml
Q 14 - Which of the following jQuery method sets the html contents of an element?
A - htmlval
B - setHtmlval
C - setInnerHtmlval
Q 15 - Which of the following jQuery method get the text contents of an element?
A - text
B - getText
C - getContent
A - textval
B - setTextval
C - setContentval
Q 17 - Which of the following jQuery method get the input value of an element?
A - getContent
B - val
C - getValue
A - setContentval
B - valval
C - setValueval
Q 19 - Which of the following jQuery method filter out elements from a set of matched
elements?
A - filterselector
B - setFilterselector
C - putFilterselector
Q 20 - Which of the following jQuery method reduce the set of matched elements to a
single element?
A - isEqualindex
B - eqindex
C - checkEqualselector
A - getIsselector
B - isselector
C - checkIsselector
Q 22 - Which of the following jQuery method removes elements matching the specified
selector from the set of matched elements?
A - getNotEqualsselector
B - isNotEqualsselector
C - notselector
A - subsetselector
B - getSubsetselector
C - sliceselector
Q 24 - Which of the following jQuery method adds more elements, matched by the
given selector, to the set of matched elements?
A - addselector
B - addElementselector
C - appendselector
Q 25 - Which of the following jQuery method adds the previous selection to the
current selection?
A - addselector
B - andSelf
C - appendselector
ANSWER SHEET
Question Number Answer Key
1 D
2 A
3 B
4 C
5 A
6 A
7 A
8 B
9 B
10 C
11 A
12 B
13 A
14 A
15 A
16 A
17 B
18 B
19 A
20 B
21 B
22 C
23 C
24 A
25 B