HTML, CSS AND JAVASCRIPT Flashcards

1
Q

What does HTML stand for?

A

Hyper text Markup Language (its the standard markup language for webpages)

HTML allows a browser to interpret and render webpages for the viewer by describing the structure and order of the webpage

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

How would you embed an image on HTML?

A

Using the <img></img> tag

It requires 2 attributes:
src : specifies the file path of the image
alt : specifies alternate text for the image just in case it cant be displayed

Images are not inserted into a webpage but rather linked to a webpage. So the <img></img> is a holding space for the referenced image

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

alt

A

An attribute (one of the 2) in a <img></img> tag

Specifies alternate text for the image just in case it cant be displayed

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

<a></a>

A

An anchor tag which defines a hyperlink which is used to link one page to another
(adds a link within a webpage(one webpage within another)
The most important attribute of the <a> tag is href</a>

href : specifies the destination of the link

so you would use it as <a href = “ https:www.bbc.co.uk”</a>

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

Tag which defines a hyperlink which is used to link one page to another

A

<a></a>

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

Tag which defines an ordered list

A

<ol>

then <li> is used to define each item in the list

so:

<ol>
<li> Dog </li>
<li> Rat </li>
<li> Cat</li>
</ol>

OUTPUTS:
(1. Dog
2. Rat
3. Cat)
</li></ol>

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

How do the takes <ol> and <ul> defer?

A

<ol> is used to define an ordered list
<ul> used to define an unordered list
</ul></ol>

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

Tag used to define an unordered list

A

<ul>

then <li> is used to define each item in the list

so:

<ul>
<li> Dog </li>
<li> Rat </li>
<li> Cat</li>
</ul>

OUTPUTS:
(. Dog
. Rat
. Cat)

(bulletpoints)
</li></ul>

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

What does CSS stand for?

A

Cascading style sheets

Its used to describe the style of a webpage

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

If I had a heading how would I change the colour of it?

A

<h1>
</h1>

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

How would i change the bordercolour of a subheading so that its dotted and blue?

A

<h2>
</h2>

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

Why is there 3 different font names for this subheading?

<h3>
</h3>

A

Because its down to the fonts the browser actually supports. If it doesnt support the first one then it will try the next one

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

Create an external CSS file for a heading and subheading with the following properties

Heading: with font color red, background color yellow
Subheading: border color blue, font color red

A

<h1>
{
font-color: red;
background-color: yellow;
}

<h2>
{
font-color: red;
border-color: blue;
}
</h2></h1>

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

How would you link an external CSS file to a HTML file?

A

Using the link tag

<link></link>

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

<div> tag
</div>

A

To divide a HTML document up and change the style of it

<div> class = "main"
<p> Hi hello</p>
</div>

so the class main will have a different style (e.g. colour) to another class so therefore the text contained within each div tag will have the properties of that class

This allows us to have different styles within one class

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

Define a class called main where the color will be green

A

.main
{
color : green;
}

(the background color will be green)

17
Q

What does this do?

CSS external file:
#orderedList
{
color: red;
}

HTML FILE:

<ol>
<li> Dog </li>
<li> Rat </li>
<li> Cat</li>
</ol>

A

It will print an ordered list with a red background color

The id tag is applied to the

18
Q

CSS can be used in two forms:

A

Internal/Embedded
Its placed inside the style tags and is entered directly into the HTML doc

External
Written in a separate doc and a link to this style sheet is added to HTML document