Unit 6-1

Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

Status Bar

Building Static Message


Not supported in modern browser.

<!DOCTYPE html>
<html>
<head>
<title></title>
<script type="text/javascript">
window.status="Welcome to status bar. This is static message";
</script>
</head>
<body>
<h3>Building Static Message</h3>
</body>
</html>

Changing message using Rollover


<!DOCTYPE html>
<html>
<body>
<h3>Image Rollover</h3>
<a onmouseover="window.status='Welcome to status bar. This is apple'">
<b>Apple</b>
</a>
<br><br>
<a onmouseover="window.status='Welcome to status bar. This is a pineapple'">
<b>PineApple</b>
</a>
</body>
</html>

Client Side Scripting (Unit 6) Arrow Computer Academy


Banner
 Loading and Displaying Banner Advertisements

<!DOCTYPE html>
<html>
<body>
<img src="mickey.jpeg" style="width: 50%">
</body>
</html>

 Change Images in Banner

<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
banner_array = new Array('mango.jpeg', 'pineapple.jpeg','banana.jpeg')
banner=0
function DisplayBanner()
{
if(document.images)
{
banner++
if (banner==banner_array.length)
{
banner = 0;
}
document.ChangeBanner.src = banner_array[banner]
setTimeout("DisplayBanner()", 5000)
}
}
</script>
</head>
<body onload="DisplayBanner()">

<img src="mango.jpeg" style="width: 50%" name="ChangeBanner">


</body>
</html>

Client Side Scripting (Unit 6) Arrow Computer Academy


 Linking a banner Advertisement to URL

<!DOCTYPE html>
<html>
<head>
<body>
<a
href="https://arrowcomputeracademy.business.site/?utm_source=gmb&utm_medium=referral">
<img src="mango.jpeg" style="width: 50%" name="ChangeBanner">
</body>
</html>

Slideshow

<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
img_array = new Array('mango.jpeg', 'pineapple.jpeg','banana.jpeg')
count=0
function SlideShow(num)
{
if(document.images)
{
count=count+num;
if (count==img_array.length)
{
count = 0;
}
if (count<0)
{
count = img_array.length-1;
}

document.img1.src = img_array[count]
}
}
</script>
</head>
<img src="mango.jpeg" style="width=200" height="300" name="img1">
<br>
<input type="button" value="Back" onclick="SlideShow(-1)">
<input type="button" value="Next" onclick="SlideShow(1)">

</body>
</html>

Client Side Scripting (Unit 6) Arrow Computer Academy

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy