I am creating an ad serving application using Flash and DHTML and I need to figure out the x and y coordinates of a flash movie that does not have a ‘id’ or ‘name’ attribute defined in the <OBJECT> or <EMBED> tags. The application is to be placed on third party web sites so I do not have access to modify the flash movies on these web sites.
I only need to make it work in Internet Explorer on the PC. The solution I came up with in JavaScript is to access the <EMBED> using document.embeds[0] and then assign the movie an id using document.embeds[0].id = “whatevername”. Only problem is that with
flash the <EMBED> tags are nested in the <OBJECT> tags and this seems to prevent the browser from being able to see the <EMBED> tags so the document.embeds[0] does not work. document.plugins[0] does not work either. I also do not know of a way to access the <OBJECT> tags using
a built in array like you can with the <EMBED> tags. Does anyone know of a solution to this problem? Perhaps there is an equivalent statement to document.embeds[0] in client side VBScript that would work? It would work to be able to set the id in either the <OBJECT> or <EMBED> tags or get the x and y coordinates some other way (which I don’t think is possible).