|
-
Sep 15th, 2001, 11:53 PM
#1
Thread Starter
Hyperactive Member
Image Change
I would like to have to image on a page and a link of text that dosn't go any where, but just simply changes the picture to another picture. Can this be done? If so how?
-
Sep 16th, 2001, 03:36 PM
#2
Fanatic Member
Try something like this:
<html>
<head>
<title></title>
<script>
var pic1 = new Image(180,216);
var pic2 = new Image(180,216);
pic1.src = 'yourpic.jpg';
pic2.src = 'yourpic_next.jpg';
function changePic(obj){
obj.src = pic2.src;
}
</script>
</head>
<body>
<br>
<center>
<img SRC = "yourpic.jpg" NAME = "imgHolder">
<br>
<a HREF = "javascript:changePic(imgHolder);">Next Image</a>
</center>
</body>
</html>
-
Sep 17th, 2001, 08:28 AM
#3
Thread Starter
Hyperactive Member
Thank You So Much! That's Just What I Needed!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|