Font size
WorksheetsUltimate Computer G8 Q2 Exam
Total questions: 116
Worksheet time: 58mins
You can change the background color of the page by using the _____ attribute: <body _____=“value”></body>
bgcolor
<mark></mark>
<video>
How do you get the source of the video from your desktop?
Embedding a Video File
You can highlight words or important information that needs attention by using the _____ tags.
bgcolor
<mark></mark>
<video>
How do you get the source of the video from your desktop?
Embedding a Video File
In order to embed a video or movie on a web page, you can use the _____ element.
You have to specify the width and height attributes so that the space required for the video is reserved when the page is loaded.
bgcolor
<mark></mark>
<video>
How do you get the source of the video from your desktop?
Embedding a Video File
1: Click on the video that you want to insert into your web page. Right-click on it, then click Properties from the menus.
2: In the properties, in the General tab, find the Location, then copy the source. Click OK.
3: Paste the source or location of the video into your program, and don’t forget to put in the file name and the file type of the video.
bgcolor
<mark></mark>
<video>
How do you get the source of the video from your desktop?
Embedding a Video File
You can embed a YouTube video file by using the tag in your HMTL document. An embedded video will play directly on your page. You can control the width and height of the window in which the video file appears.
1. Go to YouTube and open the video you would like to add to your page.
2. At the bottom of the video, click the share button, then click the embed.
3. Copy the code and paste it into your HTML document.
bgcolor
<mark></mark>
<video>
How do you get the source of the video from your desktop?
Embedding a Video File
In order to embed an audio file on a web page, you can use the <audio> element. You should also insert text content between the <audio> _____ tags for browsers that do not support the audio element.
</audio>
Linking to Audio or Video Files
Specifying Font Style
You can link YouTube video files to your website so that when a visitor clicks a button, the video file will play.
</audio>
Linking to Audio or Video Files
Specifying Font Style
To specify the style of your font, you can add an attribute as follows: <b></b>, <i></i>, <u></u>, <sup></sup>, <sub></sub>, <small></small>, <strong></strong>, <em></em>.
</audio>
Linking to Audio or Video Files
Specifying Font Style
Displays the text in boldface
<b></b>
<i></i>
<u></u>
<sup></sup>
<sub></sub>
Displays the text in italics
<b></b>
<i></i>
<u></u>
<sup></sup>
<sub></sub>
Displays the text with an underline
<b></b>
<i></i>
<u></u>
<sup></sup>
<sub></sub>
Displays the text in superscript
<b></b>
<i></i>
<u></u>
<sup></sup>
<sub></sub>
Displays the text in subscript
<b></b>
<i></i>
<u></u>
<sup></sup>
<sub></sub>
Displays the text with emphasis
<em></em>
<strong></strong>
<small></small>
Displays the text with strength
<em></em>
<strong></strong>
<small></small>
Displays the text with small size
<em></em>
<strong></strong>
<small></small>
We know that tags are composed of angle brackets. How do you then display angle brackets without having the web browser interpret them as part of a tag? In HTML, _____ provide a method of displaying special characters.
Special-character entities are written with an ampersand (&) followed by the entity name and closed by a semi-colon (;). An example of this is . As you can see, nbsp is the entity name, which means non-breaking space. It is a special character entity that displays a horizontal space (you could say it is the counterpart of <br>).
Special Character Entities
>
<
/
©
for greater than symbol or >
Special Character Entities
>
<
/
©
for less than symbol or <
Special Character Entities
>
<
/
©
for slash or /
Special Character Entities
>
<
/
©
for copyright symbol or ©
Special Character Entities
>
<
/
©
for registered symbol or ®
®
&
–
—
for ampersand or &
®
&
–
—
for en dash or –
®
&
–
—
for em dash or ––
®
&
–
—
for a non-breaking space
®
&
–
—
You can add images to your Web page with the use of the _____ tag. The _____ tag supports several attributes, but the src= attribute is the one that specifies the name and location of the image.
You can create an image using Adobe Photoshop, MS Paint, or other image editing programs. You should save your image in JPEG or PNG format and then compress the image so that loading time will be fast. You can reduce the image size by saving your file for the web. Use GIF for logos, animated images, and other images that include text and graphics.
<img>
JPEG
GIF
PNG
BMP
• Joint Photographic Experts Group, or _____ (or JPG): It supports a million colors and has a file name extension of either _____ or jpg. This file format is the most commonly used.
<img>
JPEG
GIF
PNG
BMP
• CompuServe Graphics Interchange Format, or _____, supports up to 256 colors and has the file name extension of _____. This file format is commonly used and can be animated.
<img>
JPEG
GIF
PNG
BMP
• Portable Network Graphics, or _____, supports a million colors and has a file name extension of _____.
<img>
JPEG
GIF
PNG
BMP
• Bitmap, or _____, supports a million colors and has the file name extension of _____. This type of image is not compressed. That’s why it provides the best quality for an image at the cost of file size.
<img>
JPEG
GIF
PNG
BMP
Furnishing your Web page with a design doesn’t end with typography; it only starts from there. Another good way of making your webpage attractive is through the use of images. You can insert a picture on your Web page using the empty tag <img>. To display the image on the page, you have to use the src and alt attributes.
For example: <img src=“D:\Users\PICAR_PC3\Pictures\peniel-header-banner.jpg” alt=“Peniel Header Banner” />
Inserting Graphics into a Web Page
src
alt
height
width
Indicates the image to be inserted. This attribute must be present at all times. ex: <img _____=“PICAR.bmp">
Inserting Graphics into a Web Page
src
alt
height
width
Indicates the _____ text for an image or the text that appears when the mouse hovers over the image and/or when the image cannot be displayed. ex: <img src=“PICAR.bmp" _____="Cannot display">
Inserting Graphics into a Web Page
src
alt
height
width
Indicates the _____ of the image in pixels. If the actual _____ is not specified, the image will be scaled to fit. ex: <img src=“PICAR.bmp" _____="300">
Inserting Graphics into a Web Page
src
alt
height
width
Indicates the _____ of the image in pixels. If the actual _____ is not specified, the image will be scaled to fit. ex: <img src=“PICAR.bmp" _____="300">
Inserting Graphics into a Web Page
src
alt
height
width
You can specify the background image of the page by using the background attribute inside the body tag: <body background=“value”> </body>.
The background image should not overpower the web page; otherwise, your web page’s contents will be difficult to read. You can also add a background color that matches the color of the image.
In choosing a background image, you should remember the following:
1. Use an image that will not distract from the text and main content of the page.
2. Do not use large image files because it will take a long time to load your page.
3. The background should not show boundaries and grids when tiled.
If you look closely, you'll notice that the background image appears repeatedly, and it can't be in the center. We can enhance and modify our background image using CSS, or Cascading Style Sheets, which we will cover in future lessons.
Specifying the Background image of a Page
Using Graphics as a Hyperlink
table
border
Before you can use a graphic as a hyperlink, you have to create the image first in Photoshop, Paint, or some other program.
The graphics hyperlink is commonly used as follows:
1. Link to the website’s home page.
2. Provide a link to the next, previous, or top of the current page.
3. Provide a link to large, full-size graphics.
4. Provide a link to all pages on a website.
Specifying the Background image of a Page
Using Graphics as a Hyperlink
table
border
_____s allow you to organize and arrange data into columns and rows. _____s also allow you to divide your page into sections where you can place headers, footers, and navigation links. Almost all websites are laid out using _____s. Before starting to create any kind of _____, whether to control the page layout or present data in tabular format, you should make a plan to help you build your _____ faster and more accurately. A _____ is made up of rows and columns. You can place different elements in each cell, like text or an image.
Specifying the Background image of a Page
Using Graphics as a Hyperlink
table
border
A table by default has no _____s, so notice that the example on the next page has a value of 1 for the _____ attribute, which gives the table a _____.
Specifying the Background image of a Page
Using Graphics as a Hyperlink
table
border
Tables arrange and organize content into columns and rows. Basically, they can be made via the container tags <table></table>. Each row within the table is defined by the container tags <tr></tr>. Moreover, each cell or piece of data within a row is defined by the container tags <td></td>.
Remember that the cells <td></td> are placed inside rows <tr></tr> and rows are placed inside the table <table></table>.
Creating a Table
Modifying a Table
Modifying Table Rows
Modifying Table Data
There are various ways to change the appearance of your table. You can change the thickness and color of the border, set a certain distance between the contents of the cells and the border around them, set its background color or image, etc. These various ways can be done through the table’s attributes.
Creating a Table
Modifying a Table
Modifying Table Rows
Modifying Table Data
Specifically, the rows’ <tr></tr> appearance can be changed as well, and this can be done through their attributes. By default, the contents of table rows are aligned vertically.
Creating a Table
Modifying a Table
Modifying Table Rows
Modifying Table Data
The appearance of <td></td> data in each cell can be changed through its attributes. The nowrap attribute needs no value. It just needs to be present in the tag in order for it to provide its effect. Bear in mind that the alignment set on a cell overrides the alignment set on the row.
Creating a Table
Modifying a Table
Modifying Table Rows
Modifying Table Data
Cells in the same row can be merged using the colspan attributes <td></td> and <th></th>.
Merging Cells Horizontally
Merging Cells Vertically
Merging Cells Horizontally and Vertically
Nesting Tables
Cells in the adjacent row can also be merged using the rowspan attributes <td></td> and <th></th>.
Merging Cells Horizontally
Merging Cells Vertically
Merging Cells Horizontally and Vertically
Nesting Tables
Merged cells on the same row can also be merged with cells on adjacent rows by combining the rowspan and colspan attributes.
Merging Cells Horizontally
Merging Cells Vertically
Merging Cells Horizontally and Vertically
Nesting Tables
Just like lists, tables can be nested. Web page developers use this technique to enhance the layout and structure even more.
Merging Cells Horizontally
Merging Cells Verticall
Merging Cells Horizontally and Vertically
Nesting Tables
You can also try laying out tables without the border.
Creating a Table with an Invisible Border
Adding an Image to a Table
You can add an image to a cell by using the tag pair <td><img src=“...”>.
Creating a Table with an Invisible Border
Adding an Image to a Table
Indicates the horizontal _____ment of the table. ex: <table _____=“center”></table>
left, right, center
align
background
bgcolor
border
bordercolor
Indicates the _____ image of the table. ex: <table _____=“redFlower.jpg”></table>
filename (path could be included) of the image file
align
background
bgcolor
border
bordercolor
Indicates the background color of the table. ex: <table _____=“red”></table>
assigned name or hexadecimal value of the color
align
background
bgcolor
border
bordercolor
Indicates the thickness of the _____ in pixels. ex: <table _____=“2”></table>
number of pixels
align
background
bgcolor
border
bordercolor
Indicates the color of the border. ex: <table _____=“red”></table>
assigned name or hexadecimal value of the color
align
background
bgcolor
border
bordercolor
Indicates the distance (in pixels) between the contents of the cells and the border around them.
number of pixels
cellpadding
cellspacing
width
align
valign
Indicates the distance between the cells in pixels.
number of pixels
cellpadding
cellspacing
width
align
valign
Indicates the _____ of the table in pixels or percent of the _____ displayed by the Web browser.
number of pixels or number expressed as percent
cellpadding
cellspacing
width
align
valign
Indicates the horizontal _____ment of the contents of the row.
left, right, center
cellpadding
cellspacing
width
align
valign
Indicates the vertical alignment of the contents of the row.
top, middle, bottom
cellpadding
cellspacing
width
align
valign
Indicates the _____ of the row.
assigned name or hexadecimal value of the color
bgcolor
height
align
valign
background
Indicates the _____ of the row in pixels.
number of pixels
bgcolor
height
align
valign
background
Indicates the horizontal _____ment of the contents of the cell.
bgcolor
height
align
valign
background
Indicates the vertical alignment of the contents of the cell.
bgcolor
height
align
valign
background
Indicates the _____ image of the cell.
bgcolor
height
align
valign
background
Indicates the t of the row.
bgcolor
height
width
nowrap
Indicates the _____ of the cell in pixels.
bgcolor
height
width
nowrap
Indicates the _____ of the table in pixels or percent of the _____ of the table.
bgcolor
height
width
nowrap
Inhibit word wrapping in the cell.
bgcolor
height
width
nowrap
It merges multiple cells.
colspan
rowspan
Combines multiple rows.
colspan
rowspan
A _____ is usually made up of several Web pages. What we will now do is create Web pages that are connected to one another, effectively creating a _____.
Web site
hyperlink
hypertext link
A _____ is a reference link that allows you to navigate to another page of the same document.
Web site
hyperlink
hypertext link
A _____ may be represented by colored text that is underlined or by an image.
Web site
hyperlink
hypertext link
links to a page on a different Web site
Absolute URL
Relative URL
Named anchor
hyperlink
links to a page on the same Web site
Absolute URL
Relative URL
Named anchor
hyperlink
links to a different location on the same Web page
Absolute URL
Relative URL
Named anchor
hyperlink
In this part, you will learn how to create anchors (a term used to define a _____) that allow viewers to go to another Web page or file. Anchors can also be used to make email _____s (which will be discussed later). _____s are clicked in order for viewers to jump to the page specified in them. Anchors can be made through the container tag <a></a> and by setting the value of the attribute href as the target destination page.
Absolute URL
Relative URL
Named anchor
hyperlink
Indicates the target of the anchor.
href
target
name
Indicates the behavior the Web browser will carry out.
href
target
name
It assigns a name to the anchor, defining an internal bookmark for the page.
href
target
name
the value of the href attribute or target URL will be opened in a new window.
blank
_self
_parent
_top
the value of the href attribute or target URL will be opened within the same frame.
blank
_self
_parent
_top
the value of the href attribute or target URL will be opened in the parent frameset.
blank
_self
_parent
_top
the value of the href attribute or target URL will be opened in the full body of the window.
blank
_self
_parent
_top
1 st: Go to your browser and search for the image that you want to put on your website.
2 nd: Right-click on the image, choose “Copy image address.”
3 rd: Paste the image address into your editor.
Note:
• To change the text hyperlink color:
<a href=“MSWord.png” style=“color: #cc00000”>
Microsoft Word
</a>
• To make the visited link a different color from the unvisited link so that visitors can tell where they have been:
<body vlink=“0000ff”>
To get the link to the particular image
Linking to a Page on a Different Website
Using Graphics as Links
To link to a page on a different website, you have to first find the destination file path and then copy it into your code to create the link.
To get the link to the particular image
Linking to a Page on a Different Website
Using Graphics as Links
You can use graphics or images to take you to another page on your website or to another website.
Examples of codes that you can use to add graphic links:
<a href=“https://www.microsoft.com/en-ph”>
<img src=“D:\Users\PICAR_PC3\Pictures\MSOffice.png” align=“left” width=“100px”>
</a>
To get the link to the particular image
Linking to a Page on a Different Website
Using Graphics as Links
The _____ allows you to gather feedback from your readers and work on the data to provide better service. The areas on the _____ are called fields, text fields, or text boxes. The _____ also contains command buttons, such as the Send or Reset buttons. You can also see standard controls such as check buttons, radio buttons, and list boxes.
form
action
method
get
post
The _____ attribute is responsible for indicating where the information will be passed, whether it is to another Web page or to a script.
form
action
method
get
post
The _____ attribute, on the other hand, is responsible for indicating the _____ of sending the information.
form
action
method
get
post
The _____ method of sending information appends the data to the URL. More specifically, the _____ method is basically for retrieving data
form
action
method
get
post
The _____ method may update or store data.
form
action
method
get
post
Indicates where the information will be submitted.
filename (path could be included), URL
action
method
name
type
size
Indicates the method of submitting the information.
Post, get
action
method
name
type
size
Assigns a name to the input field. The name can be used for various purposes and is required in most circumstances.
any text (without spaces)
action
method
name
type
size
Indicates the type of input field.
text, password, checkbox, radio, submit, reset
action
method
name
type
size
Indicates the size of the input field.
any number
action
method
name
type
size
Indicates the initial value of the input field. Indicates the label for the submit and reset buttons.
any text
value
checked
Creating a Textbox
Creating a Large Text Area
indicates if, by default, the input field (radio button or checkbox) is selected.
none
value
checked
Creating a Textbox
Creating a Large Text Area
Textboxes are single-line text input boxes. Usually, textboxes are used for username input and other single-line texts such as names, email addresses, etc., and can be made by keying in text as the value of the type attribute of <input>.
Additionally, you can use the value attribute to set an initial text input. The size attribute then indicates the length of the textbox.
value
checked
Creating a Textbox
Creating a Large Text Area
You can create an input field that can span several rows and columns to allow the readers to enter their feedback, requests, instructions, opinions, or any other communication.
Text areas are made via the container tag <textarea> </textarea>. The content of this tag will be displayed in the text area by default.
Example: <textarea name=“textarea1”> This is a text area.</textarea>
value
checked
Creating a Textbox
Creating a Large Text Area
Assigns a name to the text area. The name can be used for various purposes and is required in most circumstances.
any text (without spaces)
name
rows
cols
wrap
Indicates the number of rows or the height of the text area.
any number
name
rows
cols
wrap
Indicates the number of columns or the width of the text area.
any number
name
rows
cols
wrap
Indicates the type of word wrapping in the text area.
soft, hard, off
name
rows
cols
wrap
Radio buttons provide the user with a variety of choices from which only one can be selected. Radio buttons can be made by keying in radio as the value of the type attribute of <input>.
Example: <input type=“radio” name=“gender”>
Bear in mind that in a set of radio buttons, only one can be chosen; the name attribute is also used to indicate which set that radio button belongs to. Radio buttons in the same group have similar values for their name attribute.
The checked attribute is applicable for radio buttons to indicate a default selected option. Radio buttons are usually used when the choices are limited to a few.
Creating Radio Buttons
Creating Check Boxes
Creating Drop-down Menus
Unlike radio buttons, check boxes offer users a variety of choices where none, only one, or many may be selected. Check boxes can be made by keying in checkbox as the value of the type attribute of <input>.
Example: <input type=“checkbox” name=“checkboxCS”>
The checked attribute is applicable for check boxes to indicate default selected options.
Creating Radio Buttons
Creating Check Boxes
Creating Drop-down Menus
Like radio buttons, drop-down lists or drop-down menus offer users a variety of choices from which only one can be selected.
Drop-down menus are made via the container tag <select></select>.
Creating Radio Buttons
Creating Check Boxes
Creating Drop-down Menus
Assigns a name to the dropdown menu. The name can be used for various purposes and is required in most circumstances.
any text (without spaces)
name
size
value
selected
submit button
Indicates the number of visible items (lines).
any number
name
size
value
selected
submit button
Assigns a name to the dropdown menu item. The name can be used for various purposes and is required in most circumstances.
any text (without spaces)
name
size
value
selected
submit button
indicates that, by default, the item is selected.
none
name
size
value
selected
submit button
A _____ is usually placed at the end of a form, and when clicked, submits the information inputted. It can be made by keying in submit as the value of the type attribute of <input>. For example, <input type=“submit”> Furthermore, the value of the value attribute indicates the label on the button.
name
size
value
selected
submit button
A _____ or clear button is usually placed at the end of a form. When it is clicked, it clears all the input information. This can be done by keying in _____ as the value of the type attribute of <input>. For example, <input type=“_____”> Likewise, the value of the value attribute indicates the label on the button.
reset
Send File
_____ allows your website visitors to _____s to your web server. A file can be made by keying file as the value of the type attribute of <input>, while the accept attribute specifies the types of files that the server accepts (that can be submitted through a file upload).
reset
Send File
