HTML

Ace your homework & exams now with Quizwiz!

How many sessions does the sessionStorage object store data for?

1 session

How do you write an html comment?

<!-- html comment -->

Which doctype is correct for HTML5?

<!DOCTYPE html>

What is the correct HTML for creating a hyperlink to google, with text that displays "Go to Google" and opens in a new tab?

<a href="https://www.google.com" target="_blank">Go to Google</a>

What is the correct HTML element for playing audio files?

<audio>

Which html element is used to define text direction

<bdo>

What is the correct HTML for adding a background color of green to your webpage using inline styling?

<body style="background-color: green;">

What is the correct HTML for inserting a background image using inline styling?

<body style="background-image: url(background.gif);">

What is the correct HTML element for inserting a line break?

<br>

Which input type allows several options to be selected

<checkbox>

Which html element specifies self-contained content (such as illustrations, photos and captions?)

<figure>

What is the most important HTML heading?

<h1>

List some examples of block elements

<h1> (and all other headers through <h6>) <p> <ul> <ol> <div> <li>

Which HTML element defines navigation links?

<nav>

In HTML, how do you define a list where the list items are marked with letters?

<ol type="A">

What element do you use to make a numbered list?

<ol>

Which HTML element represents the result of a calculation

<output>

Which elements are used to create a dropdown list

<select> and <option>

What is the correct HTML element to define important text?

<strong>

What is the correct HTML for making a text area?

<textarea>

True or false: Inline elements normally start with a new line

false

True or false: When using the padding property you are allowed to use negative values

false

True or false: SVG images can be created and edited in any text editor and SVG is well suited for graphic intensive games

false --> SVG can be created and edited in any text editor, but it is not well suited for graphic-intensive games (canvas is good for that)

Which property is used to change the font of an element?

font-family

Which CSS property controls the text size?

font-size

How do you make the text bold?

font-weight: bold;

How do you add a background color for all <h1> elements?

h1 {background-color: orange;}

How do you make a list that lists its items with squares?

list-style-type: square;

Which HTML element starts a video over again every time it finishes?

loop

Which property is used to change the left margin of an element?

margin-left

In HTML, which attribute is used to specify that an input field must be filled out?

the required attribute (<input type="text" required>)

HTML colors can be defined using a HEX value, The HEX value combines RED, GREEN, and BLUE to make these colors. What is the correct order these colors are placed in?

#RRGGBB, A good acronym is the fake name Roy G. Biv

How do you create an email link?

<a href = "mailto:[email protected]"> linktext</a>

How do you create a link to a section inside the same HTML document?

<a href="#Section11> Go to Section 11</a> This links to wherever the Section11 id link is on the page.

What elements are used to define a description list?

<dl>, <dt>, and <dd>

What two elements are used to draw a border with a caption around some content?

<fieldset> and <legend> <fieldset> creates the border and <legend> creates the caption

What is the least important HTML heading?

<h6>

Which HTML element is used to specify a header for a document or section?

<header> (this is a semantic element, meaning it gives the page more meaning, but doesn't actually change how it looks)

Which HTML element defines a thematic break in a page(often displayed as a horizontal rule)?

<hr> - creates a horizontal line on the page

Out of the following elements, which elements are called empty elements? <hr> <img src="smiley.jpg" alt="Smiley"> <p></p>

<hr> and <img> are empty elements, they have no content and no closing tag

Which element contains an inline frame?

<iframe> (this is used to embed another document or website within your website)

What is the correct HTML for inserting an image?

<img src="image.gif" alt="MyImage">

What is the correct HTML for making a checkbox?

<input type="checkbox">

How do you define a password field?

<input type="password">

How do you create a radio button?

<input type="radio"> (this input allows you to only select one option)

What input defines a submit button?

<input type="submit">

What is the correct HTML for making a text input field?

<input type="text">

What is the correct HTML for referring to an external style sheet?

<link rel="stylesheet" type="text/css" href="style.css">

What HTML elements are used to create an image map?

<map> and <area>

Which HTML element defines marked text?

<mark>

Which HTML element is used to display a scalar measurement within a range?

<meter>

How do you define a text-area element?

<textarea> This is similar to an <input> element, but it's for longer response usually that require multiple lines

Which HTML element defines the title of a document and where does it show up?

<title> and it shows on the page tab

What element do you use to make a bulleted list?

<ul>

What is the correct HTML element for playing video files?

<video>

What is a Web Worker?

A Javascript file running in the background, without affecting the performance of the webpage

What does CSS stand for?

Cascading Style Sheets

True or false: HTML is case sensitive

False

What does HTML stand for?

Hypertext Markup Language

Where in an HTML document is the correct place to refer to an external style sheet?

In the <head> section

What does SVG stand for?

Scalable Vector Graphics

How do you group selectors?

Separate each selector with a comma

The HTML global attribute, "contenteditable" is used to:

Specify whether the content of an element should be editable or not

The HTTP status message "404" indicates what?

That the file was not found- the server couldn't find the requested page

True or False: In HTML, you can embed SVG elements directly into an HTML page.

True

True or false: HTML tables can be nested in another table?

True

True or false: the DOCTYPE declaration must be the very first thing in your HTML document before the <html> element

True

What does the action attribute in the <form> element define?

Where to send the form data when the form is submitted

Who is making the Web standards?

World Wide Web Consortium

Graphics defined by SVG are written in which format?

XML (eXtensible Markup Language)

How do you display hyperlinks without an underline?

a {text-decoration: none;}

How can you a bookmark in an HTML document (so that you can add a link to that place in the document?)

add an id to the element Ex: <h3 id="resources-section">Resources</h3> This creates a bookmark for the resources section so that you can link to it later (<a href="#resources-section">Link to Resources Bookmark</a>)

Which HTML attribute specifies an alternate text for an image, if the image cannot be displayed?

alt

Which property is used to change the background color?

background-color

What is the correct HTML for inserting a background image using external styling?

body { background-image: url(background.gif); }

How do you use external CSS to change the color of the text in the body to green?

body {color: green;}

How do you display a border like this: The top border = 10 pixels, the bottom border = 5 pixels, the left border = 20 pixels and the right border = 1pixel?

border-width:10px 1px 5px 20px;

Which CSS property is used to change the text color of an element?

color

Which HTML attribute is used to define a table cell that should span over more than one column?

colspan

Which HTML attribute for video and audio files is used to include play, pause, and volume buttons?

controls

How do you select all p elements inside a div element?

div p { color: red;}

Which script line writes Hello World! to the HTML output?

document.writeLine("Hello World!")

What html attribute is used to determine if an element is draggable?

draggable

The HTML <canvas> element is used to:

draw graphics

True or False: SVG graphics lose quality if they are resized or zoomed?

false

Which built-in HTML5 object is used to draw on the canvas?

getContext

Which storage objects is used for storing data with no expiration date?

localStorage

Which methods are used with the canvas element to draw a straight line?

moveTo( ) and lineTo( ) stroke( ) can also be used to create the actual line

What is the correct CSS syntax for making all the <p> elements bold?

p {font-weight: bold;}

Which attribute specifies a hint that describes the expected value of an input field?

placeholder <input type="text" placeholder="enter your name"> the placeholder text will show up before the user starts typing so they know they should put their name in the input

Which input type defines a slider control?

range

Which HTML attribute is used to define a table cell that should span over more than one row?

rowspan

What is the default value of the position property?

static

In HTML, what are the possible attributes to specify restrictions for the input type="number"

step value min max

Which HTML attribute is used to define inline styles?

style (ex: <h1 style="color: green;">Page Header</h1>)

How do you make each word in a text start with a capital letter?

text-transform: capitalize

What does the method attribute of the <form> element define?

the HTTP method for sending the form data

Which HTML attribute is used to show a tooltip when the mouse moves over the element?

title

True or false: An <iframe> is used to display a web page within a web page.

true

How do you select an element with id 'demo'?

#demo

How do you select elements with class name 'test'?

.test

Which character is used to indicate an end tag?

/

How do you write a CSS comment?

/ ** css comment ** /

Which element defines a caption for a table and where should it be placed?

<caption>, must be placed immediately after <table>

What is the correct HTML element to define emphasized text?

<em>

Which HTML element is used to specify a footer for a document or section?

<footer>

What is the correct HTML element for making a drop-down list?

<select> Use the select tag to make a dropdown list and nest option elements inside to add different options to it Ex: <select name="cars"> <option>Volvo</option> <option>toyota</option> <option>Audi</option> </select>

Which HTML element is used to define media resources for media elements?

<source>

List some examples of inline elements

<span> <a> <img> <input> <strong> <em> <button>

Which HTML tag is used to define an internal style sheet?

<style>

List three different table elements

<table> <tr> <td> <th>

In HTML, what does the <aside> element define?

Content aside from the page content

In HTML, onblur and onfocus are:

Event attributes (they tell you what should happen in the event that a user clicks on or off of an element)

True or false: HTML forms can be nested in another form?

False

Which input type defines a field that should contain an email address?

email

True or false: Block elements are normally displayed without starting a new line.

false

With HTML Geolocation, which method is used to get the current location of a user?

getCurrentPosition( )

What input type defines a month and year control?

month

true or false: the DOCTYPE declaration is an instruction to the browser about what version of html the page is written in

true


Related study sets

Introduction to nursing (sherpath) WEEK 1 & 2

View Set

Chapter 2: The Role of Biology in Psychology

View Set

Essentials Exam 1: chapter 28 Practice Questions

View Set

ANTH 202: Study Guide Questions Exam 1

View Set

Chapter 4, Chapter 5, Chapter 7 Combined Quiz

View Set

geo final study guide (quiz questions and answers)

View Set

Chapter 15: Cardiovascular System

View Set