Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

javascript and Action script in Netscape 6/7

Status
Not open for further replies.

cesarcesar

Programmer
Mar 5, 2003
30
Hello all,



Here’s the set up. Building for Netscape 6/7. One HTML page with Two <iframe>’s in it. One <iframe> (independent HTML pages) has a Real Video Player in it, the other has a SWF in it. Im trying to pass variables from the SWF to a separate JS page and back. In internet Explorer I would write this statement like this



window.document.myFlash.GetVariable('_global.whatvideo'); “myFlash” is the ID of the SWF



but in Netscape 6/7 I think I need to write something like this-



document.getElementById(&quot;myFlash&quot;).GetVariable('_global.whospeaking');



but its not working, can anybody help.

cesar
 
try testing for object existence.

alert(document.getElementById(&quot;myFlash&quot;))
alert(document.frames[&quot;myFrame&quot;].document.getElementById(&quot;myFlash&quot;))

etc...

You can also use the javascript console by typing javascript: in the URL bar. It will tell you were your errors are.

If you'd like to show us your site we may be able to help more easily.

Let us know if this helps. :)

Gary Haran
==========================
 
thanks for the reply, though i still seem not to be getting it to work.

this is the body of the parent HTM page -

<iframe frameborder=&quot;0&quot; id=&quot;video&quot; class=&quot;clsVideo&quot; width=&quot;241&quot; height=&quot;210&quot; src=&quot;javaonevideo.htm&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot;></iframe>

this is the body of src=&quot;javaonevideo.htm&quot; -

<div id=&quot;divRmp&quot; class=&quot;clsRmp&quot;>
<script language=&quot;javascript&quot;>whatClip(whatvideo);</script>
</div>


this is the Javascript im trying to write to control the <iframe>. this gives an error that the object is NULL or NOT AN OBJECT.

function video_visible(){
document.frames[&quot;video&quot;].document.getElementById(&quot;divRmp&quot;).style.visibility = 'show';
}



If anyone can help, my stress thanks you.

Cesar
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top