Click to See Complete Forum and Search --> : Server problems
rincewind
05-20-2003, 08:35 AM
Hi,
Is it possible for javascript code to rotate images fine on one server but for the same code to need to re-download each image at each rotation on another server?
Can this be fixed/adjusted?
Thanks
khalidali63
05-20-2003, 09:14 AM
Can you elaborate a bit more please?
Greelmo
05-20-2003, 09:14 AM
i suppose it is possible... could you post the site or source?
rincewind
05-20-2003, 09:36 AM
Sorry yeah, here's the link that works http://www.hoganstand.com/latest.html
and here's the link that doesn't
http://www.irishtrucker.com/latest.html
It's the exact same source just different gifs and slighly more pics in the first link that works.
Thanks
Greelmo
05-20-2003, 11:40 AM
that's wierd... the first link worked perfectly, but when i clicked the second link it said that page cannot be displayed.
rincewind
05-20-2003, 11:44 AM
i just tried it and it seems the whole server has gone down, try it again in a while if you get a chance, it happenend earlier today and cam back up in 10 min
Thanks
Greelmo
05-20-2003, 11:49 AM
actually, could you just post the code for the second one and i can help you like that
rincewind
05-20-2003, 11:53 AM
OK here's the code
----------------------------------------------------------------
<html>
<head>
<script type="text/javascript">
if (document.images)
{
// create an array with links to the images
adImages = new Array("images/dci.jpg","adverts/ids.gif","adverts/kogel.gif","adverts/thompson/thompson.gif","adverts/treacy.gif",
"images/ads/mercedes.gif","adverts/ids.gif","adverts/mandata.gif","images/job.gif","images/murphy.jpg",
"images/michelin.gif","images/automo.jpg","images/pirelli.jpg","images/emo.jpg",
"images/lagan.jpg","adverts/speed.gif");
// create another
// array with a list of URLs. Keep the order the same as images.
adURLs = new Array("www.dcicard.ie","www.ids.q8.com","www.kogelireland.com",
"adverts/thompson/thompson.htm","adverts/treacy.asp",
"www.mercedes-benz.ie","www.ids.q8.com","www.mandata.co.uk","topics/recruit/recruitment.asp",
"www.murphybodybuilders.com","www.michelin.co.uk/truck","www.asc.ie",
"www.pirelli.com","www.emo.ie","www.lagangroup.com","www.iol.ie/%7Erainwash/index.htm");
thisAd = -1;
thisAd1 = 0;
thisAd2 = 1;
thisAd3 = 2;
thisAd4 = 3;
thisAd5 = 4;
thisAd6 = 5;
thisAd7 = 6;
thisAd8 = 7;
thisAd9 = 8;
thisAd10 = 9;
thisAd11 = 10;
thisAd12 = 11;
thisAd13 = 12;
thisAd14 = 13;
thisAd15 = 14;
}
//cycles through each banner image.
function cycleAds()
{
if (document.images)
{
if (document.adBanner.complete)
{
if (++thisAd == adImages.length)
thisAd = 0;
document.adBanner.src = adImages[thisAd];
}
if (document.adBanner1.complete)
{
if (++thisAd1 == adImages.length)
thisAd1 = 0;
document.adBanner1.src = adImages[thisAd1];
}
if (document.adBanner2.complete)
{
if (++thisAd2 == adImages.length)
thisAd2 = 0;
document.adBanner2.src = adImages[thisAd2];
}
if (document.adBanner3.complete)
{
if (++thisAd3 == adImages.length)
thisAd3 = 0;
document.adBanner3.src = adImages[thisAd3];
}
if (document.adBanner4.complete)
{
if (++thisAd4 == adImages.length)
thisAd4 = 0;
document.adBanner4.src = adImages[thisAd4];
}
if (document.adBanner5.complete)
{
if (++thisAd5 == adImages.length)
thisAd5 = 0;
document.adBanner5.src = adImages[thisAd5];
}
if (document.adBanner6.complete)
{
if (++thisAd6 == adImages.length)
thisAd6 = 0;
document.adBanner6.src = adImages[thisAd6];
}
if (document.adBanner7.complete)
{
if (++thisAd7 == adImages.length)
thisAd7 = 0;
document.adBanner7.src = adImages[thisAd7];
}
if (document.adBanner8.complete)
{
if (++thisAd8 == adImages.length)
thisAd8 = 0;
document.adBanner8.src = adImages[thisAd8];
}
if (document.adBanner9.complete)
{
if (++thisAd9 == adImages.length)
thisAd9 = 0;
document.adBanner9.src = adImages[thisAd9];
}
if (document.adBanner10.complete)
{
if (++thisAd10 == adImages.length)
thisAd10 = 0;
document.adBanner10.src = adImages[thisAd10];
}
if (document.adBanner11.complete)
{
if (++thisAd11 == adImages.length)
thisAd11 = 0;
document.adBanner11.src = adImages[thisAd11];
}
if (document.adBanner12.complete)
{
if (++thisAd12 == adImages.length)
thisAd12 = 0;
document.adBanner12.src = adImages[thisAd12];
}
if (document.adBanner13.complete)
{
if (++thisAd13 == adImages.length)
thisAd13 = 0;
document.adBanner13.src = adImages[thisAd13];
}
if (document.adBanner14.complete)
{
if (++thisAd14 == adImages.length)
thisAd14 = 0;
document.adBanner14.src = adImages[thisAd14];
}
if (document.adBanner15.complete)
{
if (++thisAd15 == adImages.length)
thisAd15 = 0;
document.adBanner15.src = adImages[thisAd15];
}
}
// time until change to next banner
setTimeout("cycleAds()", 15000);
}
// directs the user to the website when
// the user clicks on a particular banner image.
function gotoAd()
{
document.location.href = "http://" + adURLs[thisAd];
}
function gotoAd1()
{
document.location.href = "http://" + adURLs[thisAd1];
}
function gotoAd2()
{
document.location.href = "http://" + adURLs[thisAd2];
}
function gotoAd3()
{
document.location.href = "http://" + adURLs[thisAd3];
}
function gotoAd4()
{
document.location.href = "http://" + adURLs[thisAd4];
}
function gotoAd5()
{
document.location.href = "http://" + adURLs[thisAd5];
}
function gotoAd6()
{
document.location.href = "http://" + adURLs[thisAd6];
}
function gotoAd7()
{
document.location.href = "http://" + adURLs[thisAd7];
}
function gotoAd8()
{
document.location.href = "http://" + adURLs[thisAd8];
}
function gotoAd9()
{
document.location.href = "http://" + adURLs[thisAd9];
}
function gotoAd10()
{
document.location.href = "http://" + adURLs[thisAd10];
}
function gotoAd11()
{
document.location.href = "http://" + adURLs[thisAd11];
}
function gotoAd12()
{
document.location.href = "http://" + adURLs[thisAd12];
}
function gotoAd13()
{
document.location.href = "http://" + adURLs[thisAd13];
}
function gotoAd14()
{
document.location.href = "http://" + adURLs[thisAd14];
}
function gotoAd15()
{
document.location.href = "http://" + adURLs[thisAd15];
}
</script>
</head>
<body onload="cycleAds()">
<table>
<tr>
<td>
<a href="javascript:gotoAd()">
<img name="adBanner" src="images/dci.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd1()">
<img name="adBanner1" src="adverts/ids.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd2()">
<img name="adBanner2" src="adverts/kogel.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd3()">
<img name="adBanner3" src="adverts/thompson/thompson.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd4()">
<img name="adBanner4" src="adverts/treacy.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd5()">
<img name="adBanner5" src="images/ads/mercedes.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd6()">
<img name="adBanner6" src="adverts/ids.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd7()">
<img name="adBanner7" src="adverts/mandata.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd8()">
<img name="adBanner8" src="images/job.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd9()">
<img name="adBanner9" src="images/murphy.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd10()">
<img name="adBanner10" src="images/michelin.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd11()">
<img name="adBanner11" src="images/automo.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd12()">
<img name="adBanner12" src="images/pirelli.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd13()">
<img name="adBanner13" src="images/emo.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd14()">
<img name="adBanner14" src="images/lagan.jpg" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
<tr>
<td>
<a href="javascript:gotoAd15()">
<img name="adBanner15" src="adverts/speed.gif" border="0" alt="Click here to visit these links"></a><br>
</td>
</tr>
</table>
</body>
</html>
------------------------------------------------------------------
Thanks again
Greelmo
05-20-2003, 02:22 PM
and you say that you used this EXACT code, just with different images?
khalidali63
05-20-2003, 02:24 PM
It seems like the server is down...on the other end for the second link.
rincewind
05-20-2003, 02:38 PM
Yeah the exact code, only difference was the number of images (less in the 1 that doesn't work) and it was different gifs. The server still seems to be down aswell
Greelmo
05-20-2003, 02:59 PM
to be honest, i have absolutly NO IDEA why that doesn't work...:mad: and i'm sorry i couldn't help you.
khalidali63
05-20-2003, 03:02 PM
Hey email me to see the second page once the server is online..?
rincewind
05-20-2003, 03:11 PM
no bother,
So any1 else have any ideas? roll up roll up!