logo-dw

Go Back   Dreamweaver Club Forums > Hand Coders Forum > Javascript and JS frameworks
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 03-19-2009, 03:49 PM   #1
Andymoses
 
Join Date: Jun 2008
Posts: 9
Default Java slideshow only works in template

I got this code from dynamicdrive.com as I wanted a simple sldieshow that blended the images when changing. I put my images in, and it works fine in the DW template when viewing in the browser, but in any page using that template, it only finds the first image () then fades to the little red cross. Why does this happen and can I fix it?
HTML Code:
 
<head>
<script language="JavaScript1.1">
<!--
//specify interval between slide (in mili seconds)
var slidespeed=3000
//specify images
var slideimages=new Array("../assets/logo_bl-out100x.gif","../assets/logo_bl-fill100x.gif","../assets/logo_r-out100x.gif","../assets/logo_r-fill100x.gif")
//specify corresponding links
var slidelinks=new Array("http://www.jitsufoundation.org")
var newwindow=1 //open links in new window? 1=yes, 0=no
var imageholder=new Array()
var ie=document.all
for (i=0;i<slideimages.length;i++){
imageholder[i]=new Image()
imageholder[i].src=slideimages[i]
}
function gotoshow(){
if (newwindow)
window.open(slidelinks[whichlink])
else
window.location=slidelinks[whichlink]
}
//-->
</script>
</head>
 
<body>
<p><a href="javascript:gotoshow()"><img src="../assets/logo_bl-out100x.gif" name="slide" border=0 style="filter:blendTrans(duration=2)" width=100 height=100></a>
<script language="JavaScript1.1">
<!--
var whichlink=0
var whichimage=0
var blenddelay=(ie)? document.images.slide.filters[0].duration*1000 : 0
function slideit(){
if (!document.images) return
if (ie) document.images.slide.filters[0].apply()
document.images.slide.src=imageholder[whichimage].src
if (ie) document.images.slide.filters[0].play()
whichlink=whichimage
whichimage=(whichimage<slideimages.length-1)? whichimage+1 : 0
setTimeout("slideit()",slidespeed+blenddelay)
}
slideit()
//-->
</script>
</body>

Last edited by davidj; 03-30-2009 at 06:10 AM..
Andymoses is offline   Reply With Quote
Old 03-24-2009, 02:03 AM   #2
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

It means that the path to the image is wrong. Can you put this on the web somewhere?
domedia is offline   Reply With Quote
Old 03-29-2009, 11:12 AM   #3
Andymoses
 
Join Date: Jun 2008
Posts: 9
Default

Yeah the path must have been wrong. I put in the exact path for each file and now it works fine.

Sorry to bother y'all!
Andymoses is offline   Reply With Quote
Old 03-30-2009, 02:44 AM   #4
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

No bother! Nice you got it solved.
domedia is offline   Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:02 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com