Page 1 of 1

dynamically create iframe name

Posted: Thu Nov 02, 2006 10:41 am
by rexexdesign
Hi Everybody,

I have a problem. I dynamically load a website into an iframe. But once the iframe is filled the next time I target it, it opens the website in a new window.
When I put a second iframe on that page and once it filled the first one it targeted the second one it worked. That is why I need the name of the iframe to grow by 1 everytime it is loaded.

For example: iframe1, iframe2, iframe3


Any help is greatly appreciated.

Posted: Thu Nov 02, 2006 2:45 pm
by feyd
That sounds like very strange behaviour. I think it may be better to find the reason the pages jump out of the iframe.

reason why

Posted: Thu Nov 02, 2006 3:11 pm
by rexexdesign
I am working on a flash site and it has dynamic content loading in. So the button code always changes... Flash is able to always trigger that iframe if its a static link, but since it is dynamic, it works once and then after that (the frame is filled) it opens a new window instead.

The only way I found it working is, when the name of the iframe changes. It is important that the entire page does not reload. Only the name of the iframe changes.

So lets say it is a php file and every time the iframe is loaded it the name is one higher (iframe1, iframe2) I could accomadate that in flash.

THANK YOU

Posted: Thu Nov 02, 2006 3:14 pm
by feyd
You want to change the iframe's name without refreshing the page the iframe sits in? That's Javascript.

Posted: Thu Nov 02, 2006 3:16 pm
by rexexdesign
ok... and do you know the code ;)