Vii HTML
Vii HTML
HTML
What is HTML?
• HTML stands for HyperText Markup Language.
• It is used to create and design webpages on the internet.
• HTML tells the browser how to display the content on the webpage.
HTML Tags: HTML code is written inside tags. Tags are like instructions for the browser.
o Every tag has an opening tag <tag> and a closing tag </tag>.
o The opening tag tells where the code begins.
o The closing tag tells where the code ends.
Basic Structure of an HTML Document:
<html>
<head>
<title>Title of the Page</title>
</head>
<body>
</body>
</html>
<HTML>
<HEAD> <TITLE> VI E DEMO </TITLE>
</HEAD>
<BODY BGCOLOR="AQUA">
<H1> CYBER BULLYING </H1>
<H2> CYBER BULLYING </H2>
<H3> CYBER BULLYING </H3>
<H4> CYBER BULLYING </H4>
<H5> CYBER BULLYING </H5>
<H6> CYBER BULLYING </H6>
<hr>
<img src="file:///C:/Users/HP/Downloads/OIP%20(3).jpeg" width="400px" height="400px">
<P> Cyberbullying is a form of cybercrime where individuals use online platforms, such as social media and
gaming communities, to harm others. This can involve sharing negative posts, false information, or personal
details about a victim to humiliate or threaten them. It is a serious issue that can have devastating effects on
a victim's life, including severe emotional distress and, in some cases, suicide. Unlike traditional bullying,
cyberbullying leaves behind digital traces, which can help identify the perpetrators and provide evidence for
justice. </P>
</BODY>
</HTML>
<dl>
<dt>Term 1</dt>
<dd>Description or definition for term 1.</dd>
<dt>Term 2</dt>
<dd>Description or definition for term 2.</dd>
<dt>Term 3</dt>
<dd>Description or definition for term 3.</dd>
</dl>
Code:
<html>
<head> <title> list in html </title>
</head>
<body>
<h1> programming language </h1>
<ol type="a">
<li> java </li>
<li> python </li>
<li> c++ </li>
<li> c# </li>
</ol>
<ul type="none">
<li> java </li>
<li> python </li>
<li> c++ </li>
<li> c# </li>
</ul>
<dl>
<dt> Malware </dt>
<dd> It is a malicious program </dd>
<dt> Computer network </DT>
<dd> It is a inter-connected network of computer </dd>
</dl>
</body>
</html>
<table border="1">
<tr>
<th>Header 1</th>
<th>Header 2</th>
</tr>
<tr>
<td>Data 1</td>
<td>Data 2</td>
</tr>
</table>
<HTML>
<HEAD> <TITLE> CONCEPT OF TABLES </TITLE>
<STYLE>
TABLE,TD,TH
{
BORDER: 4PX SOLID RED;
BORDER-COLLAPSE:COLLAPSE;
}
</STYLE>
</HEAD>
<BODY BGCOLOR="AQUA">
<TABLE>
<TR>
<TH> ROLL NO. </TH>
<TH> NAME </TH>
<TH> ADDRESS </TH>
<TH> PHONE NO. </TH>
</TR>
<TR>
<TD> 1 </TD>
<TD> ARJUN </TD>
<TD> MAYUR VIHAR PHASE II </TD>
<TD>989997678 </TD>
</TR>
<TR>
<TD> 2 </TD>
<TD> ANAMIKA</TD>
<TD> NOIDA </TD>
<TD>9777997678 </TD>
</TR>
<TR>
<TD> 3 </TD>
<TD>KARAN</TD>
<TD> VAISHALI GZB</TD>
<TD>9777997222</TD>
</TR>
</TABLE>
</BODY>
</HTML>
HTML Attributes
Attributes provide additional information about HTML elements. They are written inside the opening tag.
• src: Used in <img> tags to specify the image source.
• alt: Used in <img> to describe the image.
• Width: used in <img> to describe the breadth of an image
• height: used in <img> to describe the height of an image
Example:
<img src="image.jpg" alt="An example image" width="300" height="200">
HTML Formatting Tags
1. Bold Text: <b> makes text bold.
Example: <b>This is bold text</b>
2. Italic Text: <i> makes text italic.
Example: <i>This is italic text</i>
3. Underlined Text: <u> makes text underlined.
Example: <u>This is underlined text</u>
Code:
<html>
<head>
<title>Bold, Italic, and Underline Demo</title>
</head>
<body>
<h1>Bold, Italic, and Underline Example</h1>
</body>
</html>
4. Break Line: <br> adds a line break (moves text to the next line).
Example: This is the first line.<br>This is the second line.
Code:
<html>
<head>
<title>Using <br> Tag</title>
</head>
<body>
<h1>Line Break Example</h1>
<p>This is the first line.<br>This is the second line after a line break.</p>