You are on page 1of 24

Web Question

Level 2

Dr \ Hazem El-Bakry
HTML & XHTML
1. A webpage displays a picture. What tag was used to display that picture?
a. picture
b. image
c. img
d. src

2. <b> tag makes the enclosed text bold. What is other tag to make text bold?
a. <strong>
b. <dar>
c. <black>
d. <emp>

3. Tags and test that are not directly displayed on the page are written in _____ section.
a. <html>
b. <head>
c. <title>
d. <body>

4. Which tag inserts a line horizontally on your web page?


a. <hr>
b. <line>
c. <line direction="horizontal">
d. <tr>

5. What should be the first tag in any HTML document?


a. <head>
b. <title>
c. <html>
d. <document>

6. Which tag allows you to add a row in a table?


a. <td> and </td>
b. <cr> and </cr>
c. <th> and </th>
d. <tr> and </tr>

7. How can you make a bulleted list?


a. <list>
b. <nl>
c. <ul>
d. <ol>

8. How can you make a numbered list?


a. <dl>
b. <ol>
c. <list>
d. <ul>

9. How can you make an e-mail link?


a. <a href="xxx@yyy">
b. <mail href="xxx@yyy">
c. <mail>xxx@yyy</mail>
d. <a href="mailto:xxx@yyy">

10. What is the correct HTML for making a hyperlink?


a. <a href="http:// mcqsets.com">ICT Trends Quiz</a>
b. <a name="http://mcqsets.com">ICT Trends Quiz</a>
c. <http://mcqsets.com</a>
d. <a url="http://mcqsets.com">ICT Trends Quiz</a>
11. Choose the correct HTML tag to make a text italic
a. <ii>
b. <italics>
c. <italic>
d. <i>
12. Choose the correct HTML tag to make a text bold?
a. <b>
b. <bold>
c. <bb>
d. <bld>

13. What is the correct HTML for adding a background color?


a. <body color="yellow">
b. <body bgcolor="yellow">
c. <background>yellow</background>
d. <body background="yellow">

14. Choose the correct HTML tag for the smallest size heading?
a. <heading>
b. <h6>
c. <h1>
d. <head>

15. What is the correct HTML tag for inserting a line break?
a. <br>
b. <lb>
c. <break>
d. <newline>

16. What does vlink attribute mean?


a. visited link
b. virtual link
c. very good link
d. active link
Like mcqsets.com in Facebook & Google+
17. Which attribute is used to name an element uniquely?
a. class
b. id
c. dot
d. all of above

18. Which tag creates a check box for a form in HTML?


a. <checkbox>
b. <input type="checkbox">
c. <input=checkbox>
d. <input checkbox>

19. To create a combo box (drop down box) which tag will you use?
a. <select>
b. <list>
c. <input type="dropdown">
d. all of above
20. Which of the following is not a pair tag?
a. <p>
b. < u >
c. <i>
d. <img>

21. To create HTML document you require a


a. web page editing software
b. High powered computer
c. Just a notepad can be used
d. None of above

22. The special formatting codes in HTML document used to present content are
a. tags
b. attributes
c. values
d. None of above

23. HTML documents are saved in


a. Special binary format
b. Machine language codes
c. ASCII text
d. None of above

24. Some tags enclose the text. Those tags are known as
a. Couple tags
b. Single tags
c. Double tags
d. Pair tags

25. The _____ character tells browsers to stop tagging the text
a. ?
b. /
c. >
d. %

26. In HTML document the tags


a. Should be written in upper case
b. should be written in lower case
c. should be written in proper case
d. can be written in both uppercase or lowercase

27. Marquee is a tag in HTML to


a. mark the list of items to maintain inqueue
b. Mark the text so that it is hidden in browser
c. Display text with scrolling effect
d. None of above

28. There are ____ different of heading tags in HTML


a. 4
b. 5
c. 6
d. 7
29. To create a blank line in your web page
a. press Enter two times
b. press Shift + Enter
c. insert <BR> tag
d. insert <BLINE>

30. Which of the following is not a style tag?


a. <b>
b. <tt>
c. <i>
d. All of above are style tags

31. The way the browser displays the object can be modified by _____
a. attributes
b. parameters
c. modifiers
d. None of above

32. Which of the following HTML code is valid?


a. <font colour="red">
b. <font color="red">
c. <red><font>
d. All of above are style tags

33. Which of the following is an attribute related to font tag?


a. size
b. face
c. color
d. All of above are style tags

34. HTML supports


a. ordered lists
b. unordered lists
c. both type of lists
d. does not support those types

35. What tag is used to list individual items of an ordered list?


a. LI
b. OL
c. UL
d. None of above

36. When should you use path along with file name of picture in IMG tag?
a. path is optional and not necessary
b. when the location of image file and html file are different
c. when image file and html file both are on same location
d. path is always necessary when inserting image

37. Which of the following is not a valid alignment attribute?


a. Left
b. Right
c. Top
d. All of above

38. Which attribute is used with img tag to display the text if image could not load in
browser?
a. description
b. name
c. alt
d. id

39. Which attribute can be used with BODY tag to set background color green?
a. background="green"
b. bgcolor="green"
c. vlink="green"
d. None of above

40. Which attribute you’ll use with TD tag to merge two cells horizontally?
a. merge=colspan2
b. rowspan=2
c. colspan=2
d. merge=row2

41. A webpage displays a picture. What tag was used to display that picture?
a. picture
b. mage
c. img
d. src

42. <b> tag makes the enclosed text bold. What is other tag to make text bold?
a. <strong>
b. <dar>
c. <black>
d. <emp>

43. <TITLE> … </TITLE> tag must be within ________


a. Title
b. Form
c. Header
d. Body

44. Text within <EM> … </EM> tag is displayed as ________


a. bold
b. italic
c. list
d. indented

45. Text within <STRONG> … </STRONG> tag is displayed as ________


a. bold
b. italic
c. list
d. indented

46. <UL> … </UL> tag is used to ________


a. display the numbered list
b. underline the text
c. display the bulleted list
d. bold the text

47. Which tag is used to display the numbered list?


a. <OL></OL>
b. <DL></DL>
c. <UL></UL>
d. <LI></LI>

48. Which tag is used to display the large font size?


a. <LARGE></LARGE>
b. <BIG></BIG>
c. < SIZE ></SIZE>
d. <FONT></FONT>
49. <SCRIPT> … </SCRIPT> tag can be placed within ________
a. Header
b. Body
c. both A and B
d. none of the above

50. using <P> tag will


a. start a new paragraph
b. break the line
c. end the current paragraph
d. none of the above

51. <TD> … </TD> tag is used for ________


a. Table heading
b. Table Records
c. Table row
d. none of the above

52. Which is true to change the text color to red?


a. <BODY BGCOLOR=RED>
b. <BODY TEXT=RED>
c. <BODY COLOR=RED>
d. none of the above

53. With regards to e-mail addresses:


a. hey must always contain an @ symbol
b. hey can never contain spaces
c. they are case-insensitive
d. all of the above

54. A homepage is __________


a. an index of encyclopedia articles
b. where all Internet data is stored
c. required for access to the Internet
d. the first page of a website

55. Which of the following is used to explore the Internet?


a. Browser
b. Spreadsheet
c. Clipboard
d. Draw

56. What is Internet Explorer?


a. An Icon
b. A File Manager
c. A Browser
d. The Internet

57. What do I need to get onto the Internet?


a. Computer
b. Modem
c. Browser
d. All of the above

58. Output of XML document can be viewed in a


a. Word Processor
b. Web browser
c. Notepad
d. None of the above

59. Comments in XML document is given by:


a. <?-- _ _-->
b. <!_ _ _ _!>
c. <!_ _ _ _>
d. </_ _ _ _>

60. Which statement is true?


a. An XML document can have one root element
b. An XML document can have one child element
c. XML elements have to be in lower case
d. All of the above

61. What is the full form of HTML?


a. Hyper text markup language
b. Hyphenation text markup language
c. Hyphenation test marking language
d. Hyper text marking language

62. What is the full form of HTTP?


a. Hyper text transfer protocol
b. Hyper text transfer package
c. Hyphenation text test program
d. none of the above

63. What is a search engine?


a. a program that searches engines
b. a web site that searches anything
c. a hardware component
d. a machinery engine that search data

64. What is the full form of TCP/IP?


a. transmission control protocol / internet protocol
b. telephone call protocol / international protocol
c. transport control protocol / internet protocol
d. none of the above

65. HTML document start and end with which tag pairs?
a. <HEAD>….</HEAD>
b. <BODY>….</BODY>
c. <HTML>….</HTML>
d. <WEB>….</WEB>

66. Which tag is used to create body text in HTML?


a. <HEAD>
b. <TEXT>
c. <TITLE>
d. <BODY>

67. "Yahoo", "Infoseek" and "Lycos" are _________?


a. Search Engines
b. Browsers
c. News groups
d. None of the above

68. What does the .com domain represents?


a. Education domain
b. Commercial domain
c. Network
d. None of the above
69. In Satellite based communication, VSAT stands for?
a. Very Small Aperture Terminal
b. Varying Size Aperture Terminal
c. Very Small Analog Terminal
d. None of the above

70. Outlook Express is a _________


a. E-Mail Client
b. Browser
c. Search Engine
d. None of the above
css
Question 1:
What does CSS stand for?
Cascading Style Sheets
Creative Style Sheets
Colorful Style Sheets
Computer Style Sheets
Question 2:
What is the correct HTML for referring to an external style sheet?
<link rel="stylesheet" type="text/css" href="mystyle.css">
<style src="mystyle.css">
<stylesheet>mystyle.css</stylesheet>
Question 3:
Where in an HTML document is the correct place to refer to an external style sheet?
In the <body> section
At the end of the document
In the <head> section

Question 4:
Which HTML tag is used to define an internal style sheet?
<css>
<script>
<style>
Question 5:
Which HTML attribute is used to define inline styles?
font
styles
style
class
Question 6:
Which is the correct CSS syntax?
body {color: black;}
{body;color:black;}
body:color=black;
{body:color=black;}

Question 7:
How do you insert a comment in a CSS file?
/* this is a comment */
// this is a comment //
' this is a comment
// this is a comment
Question 8:
Which property is used to change the background color?
bgcolor
color
background-color
Question 9:
How do you add a background color for all <h1> elements?
all.h1 {background-color:#FFFFFF;}
h1 {background-color:#FFFFFF;}
h1.all {background-color:#FFFFFF;}

Question 10:
Which CSS property is used to change the text color of an element?
text-color
fgcolor
color
Question 11:
Which CSS property controls the text size?
text-size
font-size
font-style
text-style
Question 12:
What is the correct CSS syntax for making all the <p> elements bold?
<p style="text-size:bold;">
p {text-size:bold;}
p {font-weight:bold;}
<p style="font-size:bold;">

Question 13:
How do you display hyperlinks without an underline?
a {underline:none;}
a {decoration:no-underline;}
a {text-decoration:none;}
a {text-decoration:no-underline;}
Question 14:
How do you make each word in a text start with a capital letter?
transform:capitalize
text-style:capitalize
text-transform:capitalize
You can't do that with CSS
Question 15:
Which property is used to change the font of an element?
font-family
font-style
font-weight

Question 16:
How do you make the text bold?
style:bold;
font-weight:bold;
font:bold;
Question 17:
How do you display a border like this: The top border = 10 pixels The bottom border = 5
pixels The left border = 20 pixels The right border = 1pixel?
border-width:10px 5px 20px 1px;
border-width:10px 20px 5px 1px;
border-width:5px 20px 10px 1px;
border-width:10px 1px 5px 20px;
Question 18:
Which property is used to change the left margin of an element?
margin-left
indent
padding-left

Question 19:
When using the padding property; are you allowed to use negative values?
Yes
No
Question 20:
How do you make a list that lists its items with squares?
list-style-type: square;
list-type: square;
list: square;
Question 21:
How do you select an element with id 'demo'?
demo
#demo
*demo
.demo

Question 22:
How do you select elements with class name 'test'?
test
*test
#test
.test
Question 23:
How do you select all p elements inside a div element?
div p
div + p
div.p
Question 24:
How do you group selectors?
Separate each selector with a space
Separate each selector with a plus sign
Separate each selector with a comma

Question 25:
What is the default value of the position property?
absolute
static
fixed
relative

Question 26:
CSS stands for __________
a) Color Style Sheets
b) Cascade Sheets Style
c) Cascade Style Sheet
d) Cascading Style Sheets
Question 27:
In CSS, h1 can be called as _______
a) Selector
b) Attribute
c) Value
d) Tag
Question 28:
In css, “color:red” can be called as _____________
a) Selector
b) Rule
c) Declaration
d) Value
Question 29:
Which of the following attributes is used to specify elements to bind style rules to?
a) id
b) class
c) tag
d) all of the mentioned
Question 30:
Which selector is used to specify a rule to bind a particular unique element?
a) id
b) class
c) tag
d) both class and tag
Question 31:
In CSS, “font-size” can be called as ________
a) Selector
b) Rule
c) Property
d) Property-Name
Question 32:
_________ selectors are used to specify a group of elements.
a) id
b) class
c) tag
d) both class and tag
Question 33:
8. Which of the following tag is used to embed css in html page?
a) <script>
b) <style>
c) <css>
d) <!DOCTYPE html>
Question 34:
__________ has introduced text, list, box, margin, border, color, and background
properties.
a) css
b) html
c) ajax
d) php

Question 35:
Is it the best way to include H1 heading only one time on the web page.
a) True
b) False
JavaScript
Question 1:
Inside which HTML element do we put the JavaScript?
<scripting>
<javascript>
<script>
<js>
Question 2:
What is the correct JavaScript syntax to change the content of the HTML element below? <p
id="demo">This is a demonstration.</p>
document.getElementById("demo").innerHTML = "Hello World!";
document.getElementByName("p").innerHTML = "Hello World!";
#demo.innerHTML = "Hello World!";
document.getElement("p").innerHTML = "Hello World!";

Question 3:
Where is the correct place to insert a JavaScript?
The <head> section
Both the <head> section and the <body> section are correct
The <body> section
Question 4:
What is the correct syntax for referring to an external script called "xxx.js"?
<script src="xxx.js">
<script href="xxx.js">
<script name="xxx.js">
Question 5:
The external JavaScript file must contain the <script> tag.
True
False
Question 6:
How do you write "Hello World" in an alert box?
alertBox("Hello World");
msg("Hello World");
alert("Hello World");
msgBox("Hello World");
Question 7:
How do you create a function in JavaScript?
function = myFunction()
function:myFunction()
function myFunction()
Question 8:
How do you call a function named "myFunction"?
call function myFunction()
call myFunction()
myFunction()

Question 9:
How to write an IF statement in JavaScript?
if i = 5 then
if i == 5 then
if i = 5
if (i == 5)
Question 10:
How to write an IF statement for executing some code if "i" is NOT equal to 5?
if (i <> 5)
if i =! 5 then
if i <> 5
if (i != 5)
Question 11:
How does a WHILE loop start?
while i = 1 to 10
while (i <= 10; i++)
while (i <= 10)
Question 12:
How does a FOR loop start?
for (i = 0; i <= 5)
for (i = 0; i <= 5; i++)
for (i <= 5; i++)
for i = 1 to 5
Question 13:
How can you add a comment in a JavaScript?
'This is a comment
<!--This is a comment-->
//This is a comment
Question 14:
How to insert a comment that has more than one line?
//This comment has more than one line//
<!--This comment has more than one line-->
/*This comment has more than one line*/

Question 15:
What is the correct way to write a JavaScript array?
var colors = (1:"red", 2:"green", 3:"blue")
var colors = 1 = ("red"), 2 = ("green"), 3 = ("blue")
var colors = "red", "green", "blue"
var colors = ["red", "green", "blue"]
Question 16:
How do you round the number 7.25, to the nearest integer?
Math.rnd(7.25)
rnd(7.25)
Math.round(7.25)
round(7.25)
Question 17:
How do you find the number with the highest value of x and y?
Math.max(x, y)
Math.ceil(x, y)
ceil(x, y)
top(x, y)

Question 18:
What is the correct JavaScript syntax for opening a new window called "w2" ?
w2 = window.open("http://www.w3schools.com");
w2 = window.new("http://www.w3schools.com");
Question 19:
JavaScript is the same as Java.
True
False
Question 20:
How can you detect the client's browser name?
navigator.appName
browser.name
client.navName
Question 21:
Which event occurs when the user clicks on an HTML element?
onchange
onmouseover
onclick
onmouseclick

Question 22:
How do you declare a JavaScript variable?
variable carName;
v carName;
var carName;
Question 23:
Which operator is used to assign a value to a variable?
*
-
x
=
Question 24:
What will the following code return: Boolean(10 > 9)
NaN
false
true

Question 25:
Is JavaScript case-sensitive?
No
Yes

You might also like