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 05-26-2008, 06:47 AM   #1
jadepearl
 
Join Date: Apr 2008
Posts: 34
Default Help! Can't see movie when I click?

Hi there,

Am trying this out. Wanted to create a page where I can view several swf movies in one page. Sadly, this JS does not work. What am I doing wrong?
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01  <html>
<head>
<meta http-equiv="Content-Type"  content="text/html; charset=iso-8859-1">
<title>Untitled  Document</title>
</head>

<body>
<p>
<A  HREF="#" onclick='return  playVideo("selectDemo1","videoPlayback")'>Pool</A>
<BR>
<A  HREF="#" onclick='return playVideo("selectDemo2","videoPlayback")'>Condo  </A>
<BR>
<A HREF="#"  onclick='document.getElementById("videoPlayback").innerHTML=""; return  false'>Cancel Video</A>

</p>
<div id='videoPlayback'  style='width: 435px; height:350px; background-color:  #800000;'></div>

<div id='selectDemo1' style='display:  none'> 
<object width="425" height="350"> 
<param name="movie"  value="pool.swf">
</param> 

<param name="wmode"  value="transparent">
</param> 
<embed src="/images/pool.swf"  type="application/x-shockwave-flash" wmode="transparent" width="425"  height="350"> 
</embed> 
</object>
</div>  

<div id='selectDemo2' style='display: none'> 
<object  width="425" height="350"> 
<param name="movie"  value="condo.swf"></param> 
<param name="wmode"  value="transparent"></param> 
<embed  src="/images/condo.swf&autoplay=1" type="application/x-shockwave-flash"  wmode="transparent" width="425" height="350"> 
</embed>  
</object>
</div> 



<script  type="text/javascript">function playVideo(sourceId, targetId) { 
if  (typeof(sourceId)=='string') {sourceId=document.getElementById(sourceId);}  
if (typeof(targetId)=='string')  {targetId=document.getElementById(targetId);}  
targetId.innerHTML=sourceId.innerHTML; return  false;}
</script>

</body>
</html>
Thanks for your help, everyone!
jadepearl is offline   Reply With Quote
Old 05-28-2008, 07:37 AM   #2
pete
 
Join Date: Apr 2008
Location: in a bin
Posts: 113
Default

If you can upload the page so we can see exactly what is happening that would probably prompt people to dig in and help you out. It is impossible to test without having the movies online to view.
pete 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 04:32 AM.


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