HTML AND CSS Flashcards
(13 cards)
Name the 18 different HTML tags you need to know for the exam
- <html>
</html> - <link></link>
- <head>
</head> - <title>
</title> - <body>
</body> - <h1>
-<h2>
</h2></h1> - <h3>
</h3> - <img></img>
- <div>
</div> - <a></a>
- <form>
</form> - <input></input>
- <p>
</p> - <li>
</li> - <ol>
</ol> - <ul>
</ul> <script> </script>
<html>
</html>
- A HTML document begins with <html> and ends with </html> ; these tags are non-visual
<head>
</head>
A container for metadata that is placed between the <html> and <body> tags
<title>
</title>
- Defines the title of the document
- <title> DocumentTitle</title>
<body>
</body>
Defines the document’s main text
- There can only ever be one <body> tag in a HTML document
<h*>
- Define headings in order of importance, and therefore, size
- <h1> defines the most important heading, while <h6> defines the least important heading
</h6></h1>
<h>HeadingTitle</h>
<p>
</p>
Defines a paragraph
Browsers automatically add a single blank line before and after each <p> tag
<p>Paragraph</p>
<img></img>
Used to embed an image into a HTML document
<p> <img src=".jpg" alt="PictureTitle" height="height" width"<width"> </p>
<a></a>
Defines a hyperlink
text <a>LINKTEXT</a> text
<ol>
</ol>
Defines an ordered list
<ol>
<li>ListItem1</li>
<li>ListItem2</li>
<li>ListItem3</li>
</ol>
<ul>
</ul>
Defines an unordered (bulleted) list
<ul>
<li>ListItem1</li>
<li>ListItem2</li>
<li>ListItem3</li>
</ul>
Using CSS directly inside elements with the style attribute
Changing colour:
<h1>
Changing border style and colour:
<h2>
Changing font:
<h3>
</h3></h2></h1>
Using external CSS to define styling of elements
h1{
color:red;
background-color:yellow;
}
h2{
border-style:dotted;
border-color:blue;
border-width:thick;
}
h3{
font-family:Arial,Helvetica,sans-serif;
color:#00ff00;
}
<link></link>
.intro {
color:red;
}
.main{
color:green;
}
<div>
<div>
#orderedlist {
color:red;
}
#bulletlist{
color:green;
}
<ol>
<ul>
</ul></ol></div></div>