--> Sayadasite: UNIT – I: HYPER TEXT MARKUP LANGUAGE

Multiple Ads

Search

Menu Bar

UNIT – I: HYPER TEXT MARKUP LANGUAGE

IMPORTANT QUESTIONS (E-COMMERCE)

1-Mark Questions

1.     What is HTML?

 

HTML stands for Hypertext Markup Language. It is the standard markup language for creating web pages and web applications.

 

2.     Who invents the HTML?

 

HTML was invented by Tim Berners-Lee in the early 1990s.

 

3.     Write any two Heading tags in used in HTML.

 

Two heading tags used in HTML are:

 

o              <h1> for the main heading

 

o              <h2> for subheadings

 

4.     Which tag is used for inserting images in HTML?

 

The tag used for inserting images in HTML is <img>.

 

5.     What is the purpose of using <imag> tag.

 

The purpose of using the <img> tag is to embed images into a webpage. It specifies the location of an image file and optionally provides alternative text for users who cannot view the image.

 

6.     Write any two Text formatting tags.

 

Two text formatting tags used in HTML are:

 

o              <b> for bold text

 

 

o  <i> for italicized text

 

 

7.     <br> and <hr> tags are used for?

 

The <br> tag is used to insert a line break, and the <hr> tag is used to insert a horizontal rule (a horizontal line) in HTML. <br> is used for adding a single line break, while <hr> is used for visually separating content sections.

 

5-Mark Questions

1. Explain the Structure of HTML.

 

 Structure of HTML: HTML documents have a hierarchical structure that consists of different elements. The basic structure of an HTML document includes:

 

           <!DOCTYPE html>: This declaration specifies the HTML version being used, typically HTML5.

 

           <html>: This element wraps the entire HTML document.

 

           <head>: This section contains meta-information about the document, such as its title, character encoding, and links to external resources like CSS and JavaScript files.

           <title>: This element sets the title of the HTML document, which appears in the browser's title bar or tab.

 

           <body>: This section contains the main content of the document, including text, images, videos, and other elements.

 

           Various HTML elements like headings, paragraphs, lists, links, images, etc., are used within the <body> to structure and format the content.

2. Explain HTML Headings.

 

HTML Headings: HTML provides six levels of headings, ranging from <h1> to <h6>, where <h1> represents the highest level (main heading) and <h6> represents the lowest level (subheading). Headings are used to structure and organize content hierarchically. For example: html

<h1>Main Heading</h1>

 

<h2>Subheading</h2>

 

<h3>Sub-subheading</h3>

 

Headings not only provide visual differentiation but also help in improving accessibility and search engine optimization by indicating the importance and hierarchy of content within a document.

3. Explain HTML Paragraph.

HTML Paragraphs: Paragraphs in HTML are represented by the <p> element. They are used to

 

group and display blocks of text. Paragraphs are commonly used to organize and present textual

 

content within a webpage. For example:

 

html

 

<p>This is a paragraph of text. It may contain multiple sentences or lines.</p> <p>Another paragraph follows, providing additional information or content.</p>

 

Paragraphs automatically add white space before and after the content, visually separating it from other elements on the page. They are essential for maintaining readability and structuring textual information within HTML documents.

10-Mark Questions

1. Explain Text formatting tags used in HTML.

 

Text Formatting Tags in HTML: HTML provides several tags for formatting text to enhance its visual appearance. Some commonly used text formatting tags include:

 

           <b>: This tag is used to make text bold.

 

           <i>: Italicizes the text enclosed within it.

 

           <u>: Underlines the text.

 

           <strong>: Similar to <b>, but semantically represents strong importance.

 

           <em>: Similar to <i>, but semantically represents emphasis.

 

           <mark>: Highlights or marks the text.

 

           <sub>: Renders the text as subscript.

 

           <sup>: Renders the text as superscript.

 

           <del>: Represents deleted text.

 

           <ins>: Represents inserted text.

 

Example:

 

html

 

<p>This is <b>bold</b> text and <i>italic</i> text.</p>

 

<p>This is <u>underlined</u> text and <strong>strongly emphasized</strong> text.</p> <p>This is <em>emphasized</em> text and <mark>highlighted</mark> text.</p>

2. Explain <imag> tag with example.

 

<img> Tag in HTML: The <img> tag is used to insert images into an HTML document. It is a self-closing tag, meaning it does not have a closing tag. The <img> tag requires the src attribute, which specifies the URL of the image file, and the alt attribute, which provides alternative text for the image (useful for accessibility and SEO).

 

Example:

 

html

 

<img src="example.jpg" alt="Description of the image">

 

Explanation of attributes:

 

           src: Specifies the URL of the image file. It can be a relative or absolute URL.

 

           alt: Provides alternative text for the image. This text is displayed if the image fails to load or if

 

the user is using a screen reader.

 

Additionally, you can use other attributes like width and height to specify the dimensions of the image, title to provide a tooltip for the image, align to control the alignment of the image within the surrounding text, and more.

 

Example with additional attributes:

 

html

 

<img src="example.jpg" alt="Description of the image" width="200" height="150" title="Example Image" align="left">

 

This example will insert an image aligned to the left with a width of 200 pixels, a height of 150 pixels, and a title "Example Image".

UNIT– II Building anE-Commerce Website, Mobile Site and Apps

No comments: