m02 un07 p01

19
Unit 7 – Images Presentation 1 Web Programming

Upload: intan-jameel

Post on 20-Jan-2015

393 views

Category:

Technology


0 download

DESCRIPTION

 

TRANSCRIPT

Page 1: M02 un07 p01

Unit 7 – Images

Presentation 1

Web Programming

Page 2: M02 un07 p01

Revision

1. Define Hyperlink?

2. Name the two types of Hyperlinks?

3. Name the tag and its attribute used to create a Link?

4. How will you change the colour of the Hyperlinks?

5. Write the use of Target attribute.

Page 3: M02 un07 p01

Objectives

At the end of this presentation, you will be able to• Insert images into your Web page• Format the Images

Page 4: M02 un07 p01

Hands-On!

• Open the HTML file Image.html in C:\HTML\Unit7\Hands On Folder in Internet Explorer.

• This HTML document illustrates how to insert images in a Webpage.

Page 5: M02 un07 p01

Image Tag

• Images can be inserted into a Web page using <IMG> tag.

• Src attribute to specify the image to be displayed.

• Example:

<IMG Src=”Pinakki.gif”>

Page 6: M02 un07 p01

Formatting Images

• Image can be formatted using the attributes of <IMG> tag.

• These attributes are explained in the Table shown in the next slide.

Page 7: M02 un07 p01

Formatting Images

Page 8: M02 un07 p01

Lab Exercise

1. Open D7_1.html in Internet Explorer.

a. Identify the tag which is used to insert the image in source code D7_1.html.

b. Name the attributes which are used in source code D7_1.html.

Page 9: M02 un07 p01

Lab Exercise

2. Open D7_1.html in Internet Explorer. a. View the code in Notepad.b. Change the border style as thicker.c. Increase the height and width of the

image to 50.

Page 10: M02 un07 p01

Lab Exercise

3. Open Malaysia.html that you have created under the folder in your name in C:. Insert the picture for National Flower, Fruits and display the output as shown in the following Figure.

Page 11: M02 un07 p01

Activity 2.7.1

1. Create a Web page that explains the <IMG> tag as shown in Figure.

2. Save the HTML file as Activity1.html in C:\HTML\Unit 7\Activity folder.

3. The hyperlink More about Images at the bottom of the page should be linked to the Web page given in Activity2.

Page 12: M02 un07 p01

Activity 2.7.1 Contd.

Page 13: M02 un07 p01

Hyperlink Images

• Images can also be used as Hyperlink.

Page 14: M02 un07 p01

Hands-On!

• Open the HTML file Imagelink.html in C:\HTML\Unit7\Hands On Folder in Internet Explorer.

• This HTML document illustrates how to use images as hyperlink.

• The output is shown in the next slide

Page 15: M02 un07 p01

Hands-On!

Page 16: M02 un07 p01

Lab Exercise

4. Write a HTML code to display the output as given in the following Figure using <IMG> and <A> tag. Save the file as Flag.html under the folder in your name in C:.

When you click on the text “National Flower”, the following description should be displayed in the same page using internal hyper link.

Page 17: M02 un07 p01

Lab Exercise Contd.

Page 18: M02 un07 p01

Summary

In this presentation, you learnt the following:• Images can be inserted into a Web page

using <IMG> tag. • Images can be formatted using the attributes

of <IMG> tag.• Images can also be used as Hyperlink.

Page 19: M02 un07 p01

Assignment

1. Name the attributes that are used to change the size of the image in a Web page.

2. Write how you will insert images in your Web page?