HTML5 Flashcards

(44 cards)

1
Q

Body Element

A

< body >< /body >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Paragraph Element

A

”< p >< /p >”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Span Element

A

< span >< /span >

-used to isolate parts of in-line

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Division Element

A

< div >< /div >

- Divide body into sections

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Make “italic” Element

A

< em >< /em >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Make “bold” Element

A

< strong >< /strong >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Ordered List Element

A

< ol >< /ol >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Unordered List Element

A

< ul >< /ul >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

List Item Element

A

< li >< /li >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Image Element

A

< img src=”source” alt=”description” /img >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Video Element

A

< video src=”source” width=”1” height=”2” controls > video not supported < /video >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Heading/Subheading Element

A

< h1 >< /h1 > through < h6 >< /h6 >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Root Directory

A

Main folder where all HTML files associated with a project are stored.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Line Break Element

A

< br >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Declare an HTML Document

A

< !DOCTYPE html5 >

declaration should always be the first line of code in your HTML files. This lets the browser know what version of HTML to expect.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Container Element for HTML

A

< html > < /html >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Element to Store Website Info

A

< head >< /head >

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Titling Element

A

< title >< /title >

A webpage’s title appears in a browser’s tab.

19
Q

Anchor Element

A

< a >< /a >
< a href=”./name.html” >< /a > - internal link
< a href=”#name” >< /a > - id link
< a href=”www.website.com” >< /a > - external link

used to link to internal pages, external pages or content on the same page.

20
Q

Attribute to Specify Unique ID for Element

A

id=”unique_id”

21
Q

Add Comment to HTML

22
Q

Table Element

A

< table >< /table >

23
Q

Table Heading Element

A

< th >< /th >

Use following attributes to define column headings or row headings:

scope=”col”
scope=”row”

24
Q

Attribute to allow table data to span multiple columns or rows

A

colspan=”1”

rowspan=”1”

25
Element to define a table header
< thead >< /thead >
26
Element to define a table body
< tbody >< /tbody >
27
Element to define a table footer
< tfoot >< /tfoot >
28
How do you set up a basic table?
``` < table > < thead > < tr > < th scope="col" >< /th > < /tr > < /thead > < tbody > < tr > < td >< /td > < /tr > < /tbody > < tfoot > < td >< /td > < /tfoot > < /table > ```
29
Form Element
< form action="/example.html" method="POST" > < /form > - The action attribute determines where the information is sent. - The method attribute is assigned a HTTP verb that is included in the HTTP request.
30
Input Element
< form action="/example.html" method="POST" > < input type="text" name="first-text-field" id="first-text-field" value="hello" /> < /form > - Self-closing tag - The input element is a child of the form. - It needs to be defined by a type attribute - the name attribute will be set to the value of the input when submitted - It gets associated with a label by its id attribute - The value attribute is the pre-populated value of the form when displayed
31
Label Element
< label for="first-text-field" >First text field< /label > - Label element gets associated with an input via its "for" attribute
32
Password Input Element
< input type="password" id="user-password" name="user-password" /> -Input defined by type="password"
33
Input Element for Numbers
< input id="years" name="years" type="number" step="1" /> - Defined by type="number" - appears with + and - incremented by "step" attribute - Only allows numbers and certain related characters
34
Input Element for Slider
< input id="volume" name="volume" type="range" min="0" max="100" step="1" /> - Defined by type="range" - Includes "min" and "max" attributes - also incremented by "step" attribute
35
Input Element for Checkbox
< input id="cheese" name="topping" type="checkbox" value="cheese" /> - Defined by type="checkbox" - Needs "value" attribute defined
36
Input for Radio Button
< input type="radio" id="two" name="answer" value="2" /> - Defined by type="radio" - Needs "value" attribute defined
37
Dropdown Element
< select id="lunch" name="lunch" > < option value="1" >One< /option > < option value="2" >Two< /option > < /select > - each option needs a value attribute defined
38
Input Element for a Data List
< input type="text" list="cities" id="city" name="city" > < datalist id="cities" > < option value="New York City" >< /option > < option value="Tokyo" >< /option > < /datalist > - Use a text input with a "list" attribute defined as "id" attribute of the datalist element - each option needs a value attribute defined
39
Text Area Element
< textarea id="blog" name="blog" rows="5" cols="30" > < /textarea > - Define the number of rows and columns the text area should have via the "rows" and "cols" attributes
40
Input Element for Submit Button
< input type="submit" value="Submit" / > - Defined by type="submit" - Use "value" attribute to add user-facing message
41
Make an input required
< input type="text" value="Enter text" required / > -Simply add "required" attribute
42
Set Mininum and Maximum Values for an Input
< input type="number" min="1" max="4" / >
43
Set Mininum and Maximum Text Length for an Input
< input type="text" minlength="5" maxlength="250" required / >
44
Allow a 14-16 Digit Number to be Entered
< input type="text" required pattern="[0-9]{14,16}" / > - This technique uses regex or "regular expressions"