jQuery Quiz



jQuery Quiz # 1

The first jQuery Quiz covering Chapters 1 to 5 of Tutorial.


Q1. Which of the following is NOT true about jQuery.

A . jQuery is bunch of JavaScript programming in an external JavaScript file
B . jQuery may use a version hosted at Google or Microsoft
C . jQqury is a proprietary code
D. jQuery is not a W3 standard

Q2. Consider the following two statements

A. jQuery("p").hide();
B. $("p").hide();

Which of the following is true


A . Statement A is a valid jQuery statement while Statement B is an invalid jQuery statement
B . Statement B is a valid jQuery statement while Statement A is an invalid jQuery statement
C . Statement A as well as Statement B are invalid jQuery statements
D. Statement A as well as Statement B are valid jQuery statements

Q3. Is jQuery Library a Server Script or a Client Script

A . Server Script
B . Client Script
C . Can be Server or Client Script depending upon whether the library is at your server or Google server
D. None of the above

Q4. Consider the following jQuery statements
A. $("p").hide();
B. $("p:first").hide(); 
Which of the following is true


A . Both statements are equivalent
B . Statement A hides all html paragraph elements while statement B hides only first paragraph html statements
C . Both statements are syntactically incorrect
D. Statement A hides all html paragraph elements while statement B hides html paragraph with class =first

Q5. What is the jQuery to set the background color of all the paragraph elements to yellow

A . $("p").css("background-color","yellow")
B . $("p").layout("background-color","yellow");
C . $("p").style("background-color","yellow");
D. $("p").change("background-color","yellow");

Q6. Consider the following jQuery selector: $("p.obama"). What does it select?

A . The first p element with class="obama"
B . All p elements with id="obama"
C . All p elements with class="obama"
D. The p div element with id="obama";

Q7. What is the scripting Language for jQuery

A . Visual Basic
B . C#
C . PHP
D. javascript

Q8. The method to hide a jQuery element is

A . hide()
B . display(false)
C . visible(none)
D. hideden()

Q9. What is the jQuery function to prevent code from running, before the document is finished loading

A . document.onready()
B . document.ready()
C . body.onload()
D. document.load()

Q10. What does the jQuery selector $("div.intro") selects

A . The first div element with id="intro"
B . All div elements with id="intro"
C . All div elements with class="intro"
D. The first div element with class="intro"


Try other quizzes

Quiz 1

Quiz 2

Quiz 3