Download as pdf or txt
Download as pdf or txt
You are on page 1of 32

1) What is HTML?

2) Explain the structure of HTML documents.

The DOCTYPE is used to tell the browser to render an HTML document using the so-called
standards mode algorithm or render it with the particular browser’s older non standards
algorithm, called quirks mode.
HTML pages are divided into two sections: the head and the body, which correspond to the and
elements
The head contains descriptive elements about the document, such as its title, any style sheets
or JavaScript files it uses, and other types of meta information used by search engines and
other programs.
The body contains content (both HTML elements and regular text) that will be displayed by the
browser.

3)How to use ems and percents.?

CSS has several different units for expressing a length.


Length is a number followed by a length unit, such as 10px, 2em, etc.
Relative length units specify a length relative to another length property.
Relative length units scale better between different rendering medium.
ex:-em:Relative to the font-size of the element (2em means 2 times the size of
the current font)
Program:

PRIYANSHU SINGH(1DT19IS101)
OUTPUT:

Percent(%):Relative to the parent element


Program:

PRIYANSHU SINGH(1DT19IS101)
OUTPUT:

4)Write the division


based HTML semantic structure elements with an example

Most complex websites are absolutely packed solid with


elements. Most of these are marked with different id or class attributes.
Unfortunately, all these

PRIYANSHU SINGH(1DT19IS101)
elements can make the resulting markup confusing and hard to modify. The
idea behind using these elements is that your markup will be easier to
understand because you will be able to replace some of your
with more self explanatory HTML5 elements

PRIYANSHU SINGH(1DT19IS101)
5)Explain three types of list with an example.

OUTPUT

PRIYANSHU SINGH(1DT19IS101)
OUTPUT

OUTPUT

PRIYANSHU SINGH(1DT19IS101)
6)Illustrate the CSS Box model usage to label each of the components
of the box.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
7)Define CSS along with syntax

PRIYANSHU SINGH(1DT19IS101)
8)Explain the location of styles. Provide necessary examples.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
9)Explain the benefits of CSS .

10)Explain CSS selectors with examples.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
OUTPUT

PRIYANSHU SINGH(1DT19IS101)
11)With the sample HTML form, explain how form work.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
12)List various form related HTML elements. Discuss about query
string and micro formats.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
13)List any 6 HTML attributes. Show the usage and purpose of each
of these HTML attributes.

The href Attribute

The <a> tag defines a hyperlink.

The src Attribute

The <img> tag is used to embed an image in an HTML page

The width and height Attributes

The <img> tag should also contain the width and height attributes, which
specifies the width and height of the image (in pixels)

The alt Attribute

The required alt attribute for the <img> tag specifies an alternate text for an
image, if the image for some reason cannot be displayed. This can be due to
slow connection, or an error in the src attribute, or if the user uses a screen
reader.

The style Attribute

The style attribute is used to add styles to an element, such as color, font,
size, and more.

PRIYANSHU SINGH(1DT19IS101)
The lang Attribute

You should always include the lang attribute inside the <html> tag, to declare
the language of the Web page. This is meant to assist search engines and
browsers.

OUTPUT

PRIYANSHU SINGH(1DT19IS101)
14)Compare the two types of URL referencing. Infer which one of them
is better with appropriate justification.

An absolute URL contains more information than a relative URL does. Relative URLs
are more convenient because they are shorter and often more portable. However, you
can use them only to reference links on the same server as the page that contains
them.

PRIYANSHU SINGH(1DT19IS101)
15)List overflow properties.

16)Illustrate overflow properties with appropriate examples along with output


wherever possible.

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
17)What is the smallest header in HTML by default?

● H6
● H1
● H5
● H4

HTML headings are titles or subtitles that you want to display on a webpage.

18)Explain any six HTML elements with examples

PRIYANSHU SINGH(1DT19IS101)
An HTML element is defined by a start tag, some content, and an end tag.

PRIYANSHU SINGH(1DT19IS101)
19)

PRIYANSHU SINGH(1DT19IS101)
PRIYANSHU SINGH(1DT19IS101)
OUTPUT

PRIYANSHU SINGH(1DT19IS101)

You might also like