Comp6 Module 5 1st Quarter
Comp6 Module 5 1st Quarter
Lesson 5 -
HTML Image and Marquee
Expected Outcomes
At the end of the lesson, the learners should be able to:
1. Apply graphics to enhance the Web page output
Questions
to Ponder
In the beginning, the Web was just text, and it was really quite boring.
Fortunately, it wasn't too long before the ability to embed images (and other
more interesting types of content) inside web pages was added. There are
other types of multimedia to consider, but it is logical to start with the
humble <img> element, used to embed a simple image in a webpage. In this
lesson, we will first discuss the two main image types used on webpages: jpg
and gif. We will also learn the various ways on how to insert and customize
images, including the different alignments we can choose from.
“How do we put an image in HTML?”
Grade 6- Computer 33
Lesson 5–HTML Image and Marquee
The Concepts
that you want to insert. You can also create one
display
to your HTML. Some images on the Internet are in
the
public domain and can be used freely, but make
sure
that you use them legally.
There are different types of images filenames like
.gif, .jpg and so on. The most common images file
extensions used on the Internet are the .gif and
.jpg.
https://www.pinclipart.com/pindetail/ iTowibo_laptop-computer-woman-girl
If you have images in other file formats, you most
In order to display likely
clipart-girl-with-laptop/
Image:
<img>
The img element defines an image. In HTML the <img> tag has no end tag.
The html image is one of the highlights in designing a web, so it is very important
that you understand how to use them properly. Below is the syntax used in HTML.
What is URL?
URL stands for Uniform Resource Locator. URL stands for Uniform Resource
Locator. A URL is nothing more than the address of a given unique resource on the
Web. In theory, each valid URL points to a unique resource. Such resources can be
an HTML page, a CSS document, an image, etc. In practice, there are some
exceptions, the most common being a URL pointing to a resource that no longer
exists or that has moved. As the resource represented by the URL and the URL itself
are handled by the Web server, it is up to the owner of the web server to carefully
manage that resource and its associated URL.
To avoid error in typing the URL, you can copy it from the location of the
image. Here are ways on how you can do it:
1. Minimize the notepad program.
2. Open the folder or location of the image.
3. Right click the address bar then Copy.
4. Maximize the notepad program then right click to where you want to paste
the URL.
Code Meaning
<img src=”image.gif”> IMG stands for image
SRC stands for source
Grade 6- Computer 36
Lesson 5–HTML Image and Marquee
4. Vspace – adds vertical space in pixels
5. Hspace – adds horizontal space in pixels
Example code and output:
<HTML>
<HEAD>
<TITLE>Insert Image Border</TITLE>
</HEAD>
<BODY>
<img src="C:\Users\lenovo\Pictures\classroom.jpg"height=200 border=20
vspace=20 hspace=50>
</BODY>
</HTML>
Grade 6- Computer 37
Lesson 5–HTML Image and Marquee
The Marquee Tag <MARQUEE>
One of the best features of HTML is the marquee tag. It allows you to scroll
some text of your choice across the screen, and it doesn’t need JavaScript to make
it work. Marquee can format the color of the text background and size. The
<marquee> tag in HTML is used to create scrolling text or image in a webpage. It
scrolls either from horizontally left to right or right to left, or vertically top to bottom
or bottom to top. The marquee element comes in pairs. It means that the tag has
opening and closing elements.
Syntax: <MARQUEE>text</MARQUEE>
Output: text represent text or graphics to be moved.
To format the color of text, background, and size
Example Codes and Output:
<html>
<head>
<title>Marquee</title>
</head>
<body>
<MARQUEE LOOP="infinite" BGCOLOR="yellow" WIDTH="300">
Grade 6- Computer 38
Lesson 5–HTML Image and Marquee
Grade 6- Computer 39
Lesson 5–HTML Image and Marquee
Grade 6- Computer 40
Lesson 5–HTML Image and Marquee
<html>
<head>
<title>Marquee</title>
</head>
<body>
<marquee behavior="scroll" direction="up" scrollamount="1">Slow
Scrolling</marquee>
<marquee behavior="slide" direction="right" scrollamount="12">Little Fast
Scrolling</marquee>
<marquee behavior="alternate" direction="left" scrollamount="20">Fast
Scrolling</marquee>
</body>
</html>