U
UKAde
Can anyone tell me how I can edit the script below (which I got off the
net) so that any pictures shown are resized to 120px wide?
Thank you
Ade
<SCRIPT LANGUAGE="JavaScript">
<!--
/*
Script by FPMC at http://jsarchive.8m.com
Submitted to JavaScript Kit (http://javascriptkit.com)
For this and 400+ free scripts, visit http://javascriptkit.com
*/
//set image paths
src = ["image1.gif", "image2.gif", "image3.gif", "image4.gif"]
//set corresponding urls
url = ["http://freewarejava.com", "http://javascriptkit.com",
"http://dynamicdrive.com", "http://www.geocities.com"]
//set duration for each image
duration = 4;
//Please do not edit below
ads=[]; ct=0;
function switchAd() {
var n=(ct+1)%src.length;
if (ads[n] && (ads[n].complete || ads[n].complete==null)) {
document["Ad_Image"].src = ads[ct=n].src;
}
ads[n=(ct+1)%src.length] = new Image;
ads[n].src = src[n];
setTimeout("switchAd()",duration*1000);
}
function doLink(){
location.href = url[ct];
} onload = function(){
if (document.images)
switchAd();
}
//-->
</SCRIPT>
<A HREF="javascript:doLink();" onMouseOver="status=url[ct];return
true;"
onMouseOut="status=''">
<IMG NAME="Ad_Image" SRC="image1.gif" BORDER=0>
</A>
<p align="center"><font face="arial" size="-2">This free script
provided by <a href="http://javascriptkit.com">JavaScript
Kit</a></font></p>
net) so that any pictures shown are resized to 120px wide?
Thank you
Ade
<SCRIPT LANGUAGE="JavaScript">
<!--
/*
Script by FPMC at http://jsarchive.8m.com
Submitted to JavaScript Kit (http://javascriptkit.com)
For this and 400+ free scripts, visit http://javascriptkit.com
*/
//set image paths
src = ["image1.gif", "image2.gif", "image3.gif", "image4.gif"]
//set corresponding urls
url = ["http://freewarejava.com", "http://javascriptkit.com",
"http://dynamicdrive.com", "http://www.geocities.com"]
//set duration for each image
duration = 4;
//Please do not edit below
ads=[]; ct=0;
function switchAd() {
var n=(ct+1)%src.length;
if (ads[n] && (ads[n].complete || ads[n].complete==null)) {
document["Ad_Image"].src = ads[ct=n].src;
}
ads[n=(ct+1)%src.length] = new Image;
ads[n].src = src[n];
setTimeout("switchAd()",duration*1000);
}
function doLink(){
location.href = url[ct];
} onload = function(){
if (document.images)
switchAd();
}
//-->
</SCRIPT>
<A HREF="javascript:doLink();" onMouseOver="status=url[ct];return
true;"
onMouseOut="status=''">
<IMG NAME="Ad_Image" SRC="image1.gif" BORDER=0>
</A>
<p align="center"><font face="arial" size="-2">This free script
provided by <a href="http://javascriptkit.com">JavaScript
Kit</a></font></p>