0% found this document useful (0 votes)
17 views

html (Autosaved) (1)

The document consists of multiple choice questions, true/false statements, and programming tasks related to HTML and CSS. It covers various topics such as HTML5 tags, CSS properties, and the structure of web forms. Additionally, it includes programming exercises that require writing HTML code for different scenarios.

Uploaded by

connect.designm
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

html (Autosaved) (1)

The document consists of multiple choice questions, true/false statements, and programming tasks related to HTML and CSS. It covers various topics such as HTML5 tags, CSS properties, and the structure of web forms. Additionally, it includes programming exercises that require writing HTML code for different scenarios.

Uploaded by

connect.designm
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Multiple Choice Questions select one correct option

1. Following code is used for <video width=”320” height=”240” controls=” controls”>


<source src=”test.mp4” type=”video/mp4”> </video>
a) Display audio b) Display video c) Display text d) Display image

2. What is the correct HTML5 tag for adding a background color?


a)< body background=”yellow”> b) <background>yellow</background>
c)<body style=”background-color:white;”> d)None

3.…..tag is used to specify an inline frame


a. <jframe> b. <frameset> c. <iframe> d. <frame>

4. ___________is not a HTML5 tag.


a)<source> b) <video> c)<slider> d) All of the above

5. ______________ is the correct syntax of doctype in HTML5.


a) </doctype html> b) <doctype html!> c) <!doctype html> d) All of the above

6. Which is the correct HTML for making a text input field?


a.) <input type=”text”/> b.)<input type=”text”/> c.)<input type=”textfield”/> d.)<textfield>

7.Find out correct syntax


a)<dl><dd>HTML</dd> <dt> hypertext markup language is the authoring language used to
create documents for the World Wide web.</dl></dt>
b)<dl><dt>html</dt> <dd> hypertext markup language is the authoring language used to create
documents for the World Wide web </dl> </dd>
c)<dl><dt>html</dt><dd>hypertext marup language is the authoring language used to
create documents for the World Wide web </dd> </dl>
d)None

8.If you wanted to create a list with bullets what tag would you use?(select 2 options)
a. <ol> b. <ul> c. <li> d. <il>
9.The attribute of video element which points to the video file to be played is……….
a. Source b. Href c. Src d. File

10.Which attribute must be added to the img tag to designate the image as a Client-side?
i) Img ii) Not used iii) Usemap iv) Map

11.Which attribute is used to add video controls like play,pause,and volume in video
a)autoplay b)play c)video controls d)controls

12.For checking a regular expression in input fields of HTML forms which attribute is used.
a)Checker b) valid input c) pattern d none

13.Which of the following is not a newly added element in HTML5?


a)article b)audio c)nav d)frameset

14.Which of the following element represent header of a section or document.


a) Data-x b) Header c) Nav d) Head

15.Which of the following attribute is used to display date/time content?


a)time b)datetime c)date d)year
16.Which tag is used to defines multiple media resources for media elements audio and
video?
a) <Source> b) <Canvas> c) <Audio> d) None

17.In HTML audio/video ,….sets or returns whether the audio/video should start playing as soon as it is loaded?
a)controls b)audio Tracks c)autoplay d)currentSrc

18.In HTML Audio/video DOM, …..sets or returns whether the audio/video start over again when finished
a)loop b)autoplay c)seeking d)played

19.Which of the following is not a type of attribute for input tag?


a)day b)week c)month d)time

20.Which of the following type attributes of input element defines control for entering a telephone number?
a)mob b)tel c)mobile d)telephone

21.Which of the following is not sectioning elements?


a. <article> b. <aside> c. <nav> d. <header>

22.____________ contains the navigation menu, or other navigation functionality for the page.
a. section b. header c. nav d. aside

23.Which of the following does not lie under the attribute of <input> and is not supported by Opera?
a. url b. time c. tel d. option

24.How do we write comments in HTML5?


a. <!……> b. <…….!> c. </…….> d. </……/>

25.Which attribute is not essential under <iframe>?


a. src b. height c. width d. frameborder

26.Attributes that allow to identify particular element are ____________


a. <div> and <span> b. <meta> c. id and class d. <iframes>

27.Which of the following works as a sidebar?


a. <aside> b. <footer> c. <details> d. <section>

27.Which of the following is the correct way to create a list using the lowercase letters?
a. <ol alpha = "a" > b. <ol type = "a"> c. <ol letter = "a"> d. None of the above

28. Which of the following is the correct way to start an ordered list with the count of numeric value 4?
a. <ol type = "1" begin = "4"> b. <ol type = "1" num = "4">
c. <ol type = "1" start = "4"> d. <ol type = "1" initial = "4">

29.Which of the following HTML attribute is used to define inline styles?


a. style b. type c. class d. None of the above

30.How many ways co-ordinates can be used in Hot sopt?


A)2 B)3 c)4 D) All of these

31. What is CSS stands for?


A.Color Style Sheets B.Cascade Sheets Style C.Cascade Style Sheet D.Cascading Style Sheets
32.In CSS what does h1 can be called as?
A.Selector B.Attribute C.Value D.Tag

33.In CSS what does “color:red” can be called as


A.Selector B.Rule C.Declaration D.None of the above

34. ………………..selectors,which are used to specify a rule to bind to a particular unique element.
A. id ( preceded #) B. class(preceded .) C. tag D. both (B) and (C)

35.Which of the following property is used to set the color of a text?


A – color B – direction C - letter-spacing D - word-spacing

36. If we want to use a nice looking green dotted border around an image, which css property will we
use? (select 2 correct options)
A.border-color B.border-decoration C.border-style D.border-line

37. How will you make all paragraph elements 'RED' in color ?
A. p.all {color: red;} B .p.all {color: #990000;} C. all.p {color: #998877;} D. p {color: red;}

38.By default Hyperlinks are displayed with an underline. How do you remove the underline from all hyperlinks by
using CSS code ?
A. a {text: no-underline;} B. a {text-decoration:none;}
C. a {text-style: no-underline;} D. a {text-decoration: no-underline;}

39.The default value of "position" attribute is _________.


A. fixed B. absolute C. inherit D. relative

40.Which CSS property is used to control the text size of an element ?


A. font-style B. text-size C. font-size D. text-style

41.Which css property you will use if you want to add some margin between a DIV's border and its inner text ?
A. spacing B. margin C. padding D. inner-margin

42.What will happen in this case? <p style =”color:red” > text</p>
A) Make that specific paragraph red B) error c) nothing happens d)none of the mentioned

43. Which of the following is the correct way to applying style to a document?
A.Use an external style sheet, either by importing it or by linking to it
B.Directly embed a document-wide style in the head element of the document
C.Set an inline style rule using the style attribute directly on an element
D. All of the mentioned

44.The ……property is used to set the color of the text.


A. pallet B.colour C.color D.text-decoration

45.Which of the following is the correct way to apply styles?


A )inside an HTML element B.) inside the head section of an HTML page
C.in an external CSS file D. all of the mentioned

46. The different ways to associate styles with a HTML document is/are
A) Embedded CSS with <style> element B) Inline CSS with style attribute.
C) External CSS with <link> element. D) All of the above
Q2. True or false
1.The doctype should already be on first line of every HTML page
2. <audio> tag is used for audio in HTML5.
3. The rel attribute specifies a relationship between the current document and another document, such as a style
sheet.
4. The link element should be placed at the top of the body section.
5. CSS can add background images to documents.
6. We use Color: property to change the text color of an element.

Q. MCQ 3 correct
1. The possible values of text-align property are ______________
a. left b. justify c. top d. center e. middle f. bottom
2. Attributes used with iframe are ________
a. srcdoc b. name c. alt d. src e. href f. loop
3. Valid types of Web Hosting are ________, ______ and _________ March 23
a. shared hosting b. open hosting c. dedicated hosting d. closed hosting
e. free hosting f. non shared hosting
4. Following are the valid values of type attribute of <ol> tag
a. I b. a c. 1 d. 2 e. 0 f. C
5. Following are the attributes of <area> tag
a. href b. src c. width d. alt e. height f. src doc
6. Types of floating properties are ________0
a. left b. zero c. right d. all e. none f. dock
7. The major browsers which support features of HTML5 Are 0
a. Google Chrome b. Windows explorer c. My Documents d. Safari e. Opera f. My files
8. __________ are the different shapes to created on image map.0
a. rect b. poly c. line d. circle e. square f. hexagon
9. Which of the following methods are used for implementing styling information to an HTML document.
a. Inline CSS b. Embedded stylesheet c. Online CSS d. Linked CSS
e. External CSS f. Offline CSS
10. Following are the attribute of <audio> tag
a. width b. controls c. loop d. muted e. height f. depth
11. The elements can be positioned using ______ properties
a. top b. bottom c. middle d. right e. up f. down
12. Following are the valid values of type attribute of <input> tag _________
a. link b. date c. list d. email e. file f. start
13. Select correct CSS properties:
a. margin-left b. weight c. padding d. bgcolor e. font-size f. align

Q. 2 correct
1. Which of the following are valid values of shape attribute of <area> tag.
a. triangle b. line c. hexagon d. rect e. circle
2. Following are the correct input restrictions used for validation purpose.
a. write only b. pattern c. holder d. placeholder e. required
3. Common audio formats are _____
a. .acc b. .mp3 c. .mp4 d. .webm e. .mkv
4. Following are the common video formats _________
a. .mp3 b. .aac c. .mp4 d. .webm e. .ra
5. Following are the attributes of <area> tag.
a. href b. src c. link d. cords e. height
6. Default range of range control is _______ to _______
a. 0 b. 100 c. 120 d. 200 e. 10
7. Following attributes of <input> tag are used to specify minimum and maximum value for input field.
a. min b. disabled c. multiple d. max e. minimum
8. To create items in definition list _______ and ______ tag are used.
a. <dt> b. <dd> c. <dm> d. <ul> e. <ol>
9. Text decoration property is used to add __________
a. line-through b. strike-through c. underline d. justify e. middle
10. Following are the values of Display properties _______
a. Middle b. Inline c. Block d. top e. bottom

Q. Programs
1. Write a html code to accept STUDENT DETAILS. The form should have the following details: Student Name, Date of
Birth (Compulsory field) and Attendance (in number form). The data should be sent to the server.
2. Write html code to display a text World is Beautiful having font size 35, spacing between the letters using CSS.
3. Write a html program to create an ordered list of 3 courses (FYBCom, SYBCom, TYBCom) in Bhaktivedanta College
and under each stream mention 3 subjects taught in Unordered listing.
4. Write a html program to create nested list having names of two students. Add ordered list of 3 subjects that they
have selected under each name.
5. Write HTML5 code with CSS as follows:
a) Create ordered list with names of tourist cities.
b) Create unordered list with tourist places of those cities.
c) Divide the list into two sections left and right by using CSS
6. Write html program to display Information Technology in bold format and Times New Roman font. Add any two
sentences about IT subject below in orange color. Use inline CSS.
7. Design a personal information form in html that accept Name, age, address, current status as Working or Non-
Working and Educational Qualification. Buttons should be provided for clearing and submitting data.
8. Write html program to accept Student Name, Date of Birth and attendance percentage in number form. The data
should be sent to the server.
9. Write Program using HTML with following CSS specifications:
a) The background color of the company name should be in green.
b) The text color of the company name should be red.
c) The heading should be large with font "Comic Sans MS".
d) The description of the company should be displayed in blue color in a paragraph.
10. Write a html program to create an ordered list having names of two friends. Add unordered list of their hobbies
under each name. (The program code should display nested list.)
11. Write html program to create an ordered list of 3 languages used for speaking and unordered list having 2
computer languages.
12. Write a html program to create an ordered list of Tea and Coffee and unordered list under Coffee as Black Coffee
and cold Coffee.
13. Write a html code to display Good Morning having bold effect and underline. Also display Welcome to our page
centrally in 30 pixel font size. Use inline CSS to achieve the above.
14. Write a html program to accept Email Id of the Hotel, Date of Foundation, Number of tables in hotel. The data
should be sent to the server.
15. Write a html program to create registration form to accept name, mobile no., date of birth. The form should
have register caption in the button to submit the data.

You might also like