0% found this document useful (0 votes)
4 views1 page

HTML Interview Questions-2

The document provides a list of HTML interview questions and answers aimed at freshers. It covers fundamental concepts such as the definition of HTML, the purpose of tags, differences between HTML and HTML5, and various HTML elements and attributes. Key topics include semantic elements, forms, and the distinction between block and inline elements.

Uploaded by

nranganathn123
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views1 page

HTML Interview Questions-2

The document provides a list of HTML interview questions and answers aimed at freshers. It covers fundamental concepts such as the definition of HTML, the purpose of tags, differences between HTML and HTML5, and various HTML elements and attributes. Key topics include semantic elements, forms, and the distinction between block and inline elements.

Uploaded by

nranganathn123
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

HTML Interview Questions & Answers (Freshers)

1. What is HTML?
HTML is a markup language used to create the structure of web pages.

2. Why is HTML used?


To structure content like text, images, links, and forms.

3. What are HTML tags?


Tags define elements and are enclosed in angle brackets.

4. Difference between HTML and HTML5?


HTML5 supports audio, video, semantic tags, and local storage.

5. What are empty elements?


Elements without closing tags like br, hr, img, input.

6. What is an attribute?
Attributes provide extra information about elements.

7. Difference between div and span?


Div is block-level, span is inline.

8. What are semantic elements?


Elements that describe their meaning like header, footer, section.

9. What is DOCTYPE?
It tells the browser the document type is HTML5.

10. Difference between block and inline elements?


Block takes full width, inline takes content width.

11. What is a form?


Used to collect user input.

12. Difference between id and class?


Id is unique, class can be reused.

13. What is alt attribute?


Provides alternative text for images and accessibility.

14. What is iframe?


Used to embed another webpage.

15. Is HTML case sensitive?


No, but lowercase is recommended.

You might also like