HTML 5 Viva questions
What are the new features provided in HTML5?
Some of the new features provided in HTML5 are:
•It provides supportfor local storage
•New form controls,like calendar,date, time,email,url,search
•<canvas> elementis provided to facilitate 2D drawing
•The <video> and <audio> elements are provided for media playback
•New content-specific elements are provided.For e.g. <article>, <header>,<footer>, <nav>, <section>
HTML interview questions and answers
2. Tell us something about the new <canvas> element.
- The new <canvas> elementprovided by HTML 5 aids in 2D drawing.
- It uses the tag <canvas>.
- This tag helps in drawing graphics through scripting usuallyJavaScript.
3. What are the various elements provided by HTML 5 for media content?
<audio> and <video> elements are provided by HTML5 for media playback.
The tags used are:
a.) <audio> - It defines sound content.
b.) <video> - It defines a video or a movie.
c.) <source> - This tag defines the multiple media resources for <video> and <audio>.
d.) <embed> - It provides a container for an external application or interactive content.
e.) <track> - It defines text tracks for <video> and <audio>.
4. What are the new Form elements made available in HTML5?
The new Form elements in HTML5 provide for a better functionality. The tags provided to carry out these functions are:
a.) <datalist> - It specifies a listof options for inputcontrols.These options are pre-defined.
b.) <keygen> - This tag defines a key-pair generator field.
c.) <output> - It defines the resultof a calculation.
5. What are the various tags provided for better structuring in HTML5?
The various tags provided for better structuring in HTML 5 are:
a.) <article> - This tag defines an article.
b.) <aside> - It defines contentother than the page content.
c.) <bdi> - This tag isolates a part of text for formatting in a different direction from other text.
d.) <command> - It defines a command button to be invoked by the user.
e.) <details> - It defines additional details thatcan be viewed or hidden by the user.
f.) <dialog> - It defines a dialog box.
g.) <figure> - This tag specifies contentlike illustrations,diagrams,photos,code listings,etc.
h.) <figcaption> - It is used to provide a caption for a <figure> element
i.) <footer> - This tag defines a footer for a documentor section
j.) <header> - This tag is used to define a header for a documentor section
k.) <hgroup> - When there are multiple levels in a heading,it groups a setof <h1> to <h6> elements.
l.) <mark> - It defines highlighted text.
m.)<meter> - It defines a scalar measurementwithin a known range.
n.) <nav> - It defines links for navigation
o.) <progress> - This tag exhibits the progress ofa task
p.) <ruby> - It defines a ruby annotation for EastAsian typography
q.) <rt> - It defines an explanation/pronunciation ofcharacters for East Asian typography
r.) <rp> - This tag tells the system whatto displayin browsers thatdo not supportruby annotations.
s.) <section> - It defines a section in a document
t.) <summary> - It provides a visible heading for a <details> element
u.) <time> - This tag defines a date/time
v.) <wbr> - This tag defines a line-break
6. Which elements of HTML 4.01 are no more a part of HTML5?
Following elements ofHTML 4.01 are no more a part of HTML 5:
<acronym>
<applet>
<basefont>
<big>
<center>
<dir>
<font>
<frame>
<frameset>
<noframes>
<strike>
<tt>
7. What is SVG?
•SVG is the abbreviation for Scalable Vector Graphics and is recommended byW3C.
•It is used to define vector-based graphics for the Web
•The graphics are defined in XML format
•An importantquality of SVG graphics is thattheir quality is maintained even when they are zoomed or resized.
•All the elementand attributes ofSVG files can be animated
8. What are the advantages of SVG over other image format like JPEG or GIF?
Following are the main advantages ofusing SVG over other image formats:
- It is possible to scale the SVG images.
- They can be created and edited with any text editor
- The print quality of these image is high at any resolution.
- It is possible to zoom the SVG images withoutany degradation in the quality.
- SVG images can be searched,indexed,scripted,and compressed
9. Differentiate between Canvas and SVG.
The table below shows some importantdifferences between Canvas and SVG:
- Canvas is resolution dependentwhile SVG is not.
- Canvas does not provide any supportfor event handlers while SVG does.
- Canvas is suitable for graphic-intensive games while SVGis not suitable for gaming.
- Canvas is suitable for small rendering areas while SVG is suitable for large rendering areas like Google maps.
10. What is a Canvas? What is the default border size of a canvas?
Canvas is a rectangular area on a HTML page,specified with the tag <canvas>.
By default, a canvas has no border.To get a border on the canvas, a style attribute is required to be used.
11. Which methods are used to draw a straight line on a Canvas?
Following methods are used to draw a straightline on a Canvas:
- moveTo(x,y) – It defines the starting co-ordinates ofthe line
- lineTo(x,y) – It defines the ending co-ordinates ofthe line
- The actual line is drawn with the help of a method like stroke()
12. What are gradients in Canvas used for? What are their different types?
Gradients in canvas are used to fill rectangles,circles,lines etc.
The gradients in Canvas are of two types:
- createLinearGradient(x,y,x1,y1) – It creates a linear gradient
- createRadialGradient(x,y,r,x1,y1,r1) – It creates a radial/circular gradient
13. Which method is used to draw an image on the canvas?
drawImage(image,x,y) method is used to draw an image on the canvas.
14. HTML 5 provides drag and drop facility. How do you make an image draggable?
To make an image draggable,the draggable attribute is setto true:
<img draggable="true">
15. Can HTML 5 get the geographical position of a user?
- Yes, HTML 5 can get the location of a user with the use of Geolocation API.
- Use getCurrentPosition() method to get the user’s currentposition.

More Related Content

PPTX
Bootstrap ppt
PPTX
Microsoft Dynamics NAV 2016 - "A users guide"
PDF
Training report on web developing
PPTX
Windows 11 what are some big features, upgrades & changes
 
PPT
Android - Android Intent Types
PPTX
Bootstrap 5 ppt
PPTX
House Rental Management System Presentation
PPTX
online mobile phone shopping
Bootstrap ppt
Microsoft Dynamics NAV 2016 - "A users guide"
Training report on web developing
Windows 11 what are some big features, upgrades & changes
 
Android - Android Intent Types
Bootstrap 5 ppt
House Rental Management System Presentation
online mobile phone shopping

What's hot (20)

PPTX
Hotel-Management-System Hotel-Management-SystemHotel-Management-SystemHotel-M...
DOC
Online Fitness Gym Documentation
PPTX
Web Development In 2018
PPT
Learning HTML
PDF
android app development training report
PPTX
Web development
PPTX
Hotel management system
DOC
Android Report
PPTX
Introduction to React JS
PDF
bhargav_flowing-fountain
PPTX
1 Fundamentals of EDP (2).pptx
PPTX
Bootstrap PPT by Mukesh
PPT
Android Application Development Using Java
PDF
Elements of Computer Networking: An Integrated Approach (Concepts, Problems a...
PDF
Introduction to asp.net
PPTX
Hotel management system presentation
PDF
Hospital Management System SRS
PDF
FRONT-END WEB DEVELOPMENT WITH REACTJS
PDF
React js
Hotel-Management-System Hotel-Management-SystemHotel-Management-SystemHotel-M...
Online Fitness Gym Documentation
Web Development In 2018
Learning HTML
android app development training report
Web development
Hotel management system
Android Report
Introduction to React JS
bhargav_flowing-fountain
1 Fundamentals of EDP (2).pptx
Bootstrap PPT by Mukesh
Android Application Development Using Java
Elements of Computer Networking: An Integrated Approach (Concepts, Problems a...
Introduction to asp.net
Hotel management system presentation
Hospital Management System SRS
FRONT-END WEB DEVELOPMENT WITH REACTJS
React js
Ad

Viewers also liked (11)

PDF
HTML practicals
DOCX
Javascript viva questions
DOCX
Practical file on web technology(html)
DOCX
Servlet viva questions
DOCX
CLOUD-BASED MULTIMEDIA CONTENT PROTECTION SYSTEM
DOCX
Web Technology Lab File
DOC
Viva questions
DOC
Practical File Itm
PDF
Web technology lab manual
DOC
Dbms lab questions
DOC
Type of auditing
HTML practicals
Javascript viva questions
Practical file on web technology(html)
Servlet viva questions
CLOUD-BASED MULTIMEDIA CONTENT PROTECTION SYSTEM
Web Technology Lab File
Viva questions
Practical File Itm
Web technology lab manual
Dbms lab questions
Type of auditing
Ad

Similar to Html viva questions (20)

PDF
HTML 5 Step By Step - Ebook
PPTX
New Elements & Features in HTML5
PDF
Html5 CSS3 jQuery Basic
PPTX
web designing course bangalore
PDF
PDF
Html5
PPTX
Html5 tutorial for beginners
PDF
Html5
PPTX
HTML5-Tutorial-For-Beginn.6202488.pptx
 
DOC
HTML5 vs Flash : Term paper at VGSOM, IIT Kharagpur
ODP
Html5
ODP
Html5
PPT
Introduction of html5
PPTX
Html5
PDF
Jsf2 html5-jazoon
PPT
Brief on Html5
PPT
Is it time to start using HTML 5
PPTX
PPT
HTML 5 Overview
HTML 5 Step By Step - Ebook
New Elements & Features in HTML5
Html5 CSS3 jQuery Basic
web designing course bangalore
Html5
Html5 tutorial for beginners
Html5
HTML5-Tutorial-For-Beginn.6202488.pptx
 
HTML5 vs Flash : Term paper at VGSOM, IIT Kharagpur
Html5
Html5
Introduction of html5
Html5
Jsf2 html5-jazoon
Brief on Html5
Is it time to start using HTML 5
HTML 5 Overview

Recently uploaded (20)

PPTX
Management Information system : MIS-e-Business Systems.pptx
PDF
Present and Future of Systems Engineering: Air Combat Systems
PPT
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
PPTX
A Brief Introduction to IoT- Smart Objects: The "Things" in IoT
PPTX
Principal presentation for NAAC (1).pptx
PPTX
wireless networks, mobile computing.pptx
PDF
August 2025 - Top 10 Read Articles in Network Security & Its Applications
PPTX
tack Data Structure with Array and Linked List Implementation, Push and Pop O...
PPTX
ai_satellite_crop_management_20250815030350.pptx
PPTX
Chapter 2 -Technology and Enginerring Materials + Composites.pptx
PPTX
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
PDF
distributed database system" (DDBS) is often used to refer to both the distri...
PDF
UEFA_Carbon_Footprint_Calculator_Methology_2.0.pdf
PDF
Exploratory_Data_Analysis_Fundamentals.pdf
PDF
Influence of Green Infrastructure on Residents’ Endorsement of the New Ecolog...
PDF
Accra-Kumasi Expressway - Prefeasibility Report Volume 1 of 7.11.2018.pdf
PPTX
"Array and Linked List in Data Structures with Types, Operations, Implementat...
PPTX
MAD Unit - 3 User Interface and Data Management (Diploma IT)
PDF
Computer System Architecture 3rd Edition-M Morris Mano.pdf
PDF
MLpara ingenieira CIVIL, meca Y AMBIENTAL
Management Information system : MIS-e-Business Systems.pptx
Present and Future of Systems Engineering: Air Combat Systems
Chapter 1 - Introduction to Manufacturing Technology_2.ppt
A Brief Introduction to IoT- Smart Objects: The "Things" in IoT
Principal presentation for NAAC (1).pptx
wireless networks, mobile computing.pptx
August 2025 - Top 10 Read Articles in Network Security & Its Applications
tack Data Structure with Array and Linked List Implementation, Push and Pop O...
ai_satellite_crop_management_20250815030350.pptx
Chapter 2 -Technology and Enginerring Materials + Composites.pptx
ASME PCC-02 TRAINING -DESKTOP-NLE5HNP.pptx
distributed database system" (DDBS) is often used to refer to both the distri...
UEFA_Carbon_Footprint_Calculator_Methology_2.0.pdf
Exploratory_Data_Analysis_Fundamentals.pdf
Influence of Green Infrastructure on Residents’ Endorsement of the New Ecolog...
Accra-Kumasi Expressway - Prefeasibility Report Volume 1 of 7.11.2018.pdf
"Array and Linked List in Data Structures with Types, Operations, Implementat...
MAD Unit - 3 User Interface and Data Management (Diploma IT)
Computer System Architecture 3rd Edition-M Morris Mano.pdf
MLpara ingenieira CIVIL, meca Y AMBIENTAL

Html viva questions

  • 1. HTML 5 Viva questions What are the new features provided in HTML5? Some of the new features provided in HTML5 are: •It provides supportfor local storage •New form controls,like calendar,date, time,email,url,search •<canvas> elementis provided to facilitate 2D drawing •The <video> and <audio> elements are provided for media playback •New content-specific elements are provided.For e.g. <article>, <header>,<footer>, <nav>, <section> HTML interview questions and answers 2. Tell us something about the new <canvas> element. - The new <canvas> elementprovided by HTML 5 aids in 2D drawing. - It uses the tag <canvas>. - This tag helps in drawing graphics through scripting usuallyJavaScript. 3. What are the various elements provided by HTML 5 for media content? <audio> and <video> elements are provided by HTML5 for media playback. The tags used are: a.) <audio> - It defines sound content. b.) <video> - It defines a video or a movie. c.) <source> - This tag defines the multiple media resources for <video> and <audio>. d.) <embed> - It provides a container for an external application or interactive content. e.) <track> - It defines text tracks for <video> and <audio>. 4. What are the new Form elements made available in HTML5? The new Form elements in HTML5 provide for a better functionality. The tags provided to carry out these functions are: a.) <datalist> - It specifies a listof options for inputcontrols.These options are pre-defined. b.) <keygen> - This tag defines a key-pair generator field. c.) <output> - It defines the resultof a calculation. 5. What are the various tags provided for better structuring in HTML5? The various tags provided for better structuring in HTML 5 are: a.) <article> - This tag defines an article. b.) <aside> - It defines contentother than the page content. c.) <bdi> - This tag isolates a part of text for formatting in a different direction from other text. d.) <command> - It defines a command button to be invoked by the user. e.) <details> - It defines additional details thatcan be viewed or hidden by the user. f.) <dialog> - It defines a dialog box. g.) <figure> - This tag specifies contentlike illustrations,diagrams,photos,code listings,etc. h.) <figcaption> - It is used to provide a caption for a <figure> element i.) <footer> - This tag defines a footer for a documentor section j.) <header> - This tag is used to define a header for a documentor section k.) <hgroup> - When there are multiple levels in a heading,it groups a setof <h1> to <h6> elements. l.) <mark> - It defines highlighted text. m.)<meter> - It defines a scalar measurementwithin a known range. n.) <nav> - It defines links for navigation o.) <progress> - This tag exhibits the progress ofa task p.) <ruby> - It defines a ruby annotation for EastAsian typography q.) <rt> - It defines an explanation/pronunciation ofcharacters for East Asian typography r.) <rp> - This tag tells the system whatto displayin browsers thatdo not supportruby annotations.
  • 2. s.) <section> - It defines a section in a document t.) <summary> - It provides a visible heading for a <details> element u.) <time> - This tag defines a date/time v.) <wbr> - This tag defines a line-break 6. Which elements of HTML 4.01 are no more a part of HTML5? Following elements ofHTML 4.01 are no more a part of HTML 5: <acronym> <applet> <basefont> <big> <center> <dir> <font> <frame> <frameset> <noframes> <strike> <tt> 7. What is SVG? •SVG is the abbreviation for Scalable Vector Graphics and is recommended byW3C. •It is used to define vector-based graphics for the Web •The graphics are defined in XML format •An importantquality of SVG graphics is thattheir quality is maintained even when they are zoomed or resized. •All the elementand attributes ofSVG files can be animated 8. What are the advantages of SVG over other image format like JPEG or GIF? Following are the main advantages ofusing SVG over other image formats: - It is possible to scale the SVG images. - They can be created and edited with any text editor - The print quality of these image is high at any resolution. - It is possible to zoom the SVG images withoutany degradation in the quality. - SVG images can be searched,indexed,scripted,and compressed 9. Differentiate between Canvas and SVG. The table below shows some importantdifferences between Canvas and SVG: - Canvas is resolution dependentwhile SVG is not. - Canvas does not provide any supportfor event handlers while SVG does. - Canvas is suitable for graphic-intensive games while SVGis not suitable for gaming. - Canvas is suitable for small rendering areas while SVG is suitable for large rendering areas like Google maps. 10. What is a Canvas? What is the default border size of a canvas? Canvas is a rectangular area on a HTML page,specified with the tag <canvas>. By default, a canvas has no border.To get a border on the canvas, a style attribute is required to be used. 11. Which methods are used to draw a straight line on a Canvas? Following methods are used to draw a straightline on a Canvas: - moveTo(x,y) – It defines the starting co-ordinates ofthe line - lineTo(x,y) – It defines the ending co-ordinates ofthe line - The actual line is drawn with the help of a method like stroke() 12. What are gradients in Canvas used for? What are their different types?
  • 3. Gradients in canvas are used to fill rectangles,circles,lines etc. The gradients in Canvas are of two types: - createLinearGradient(x,y,x1,y1) – It creates a linear gradient - createRadialGradient(x,y,r,x1,y1,r1) – It creates a radial/circular gradient 13. Which method is used to draw an image on the canvas? drawImage(image,x,y) method is used to draw an image on the canvas. 14. HTML 5 provides drag and drop facility. How do you make an image draggable? To make an image draggable,the draggable attribute is setto true: <img draggable="true"> 15. Can HTML 5 get the geographical position of a user? - Yes, HTML 5 can get the location of a user with the use of Geolocation API. - Use getCurrentPosition() method to get the user’s currentposition.