Jump to content


Please Help Iframe


12 replies to this topic

#1 Futingkiller

    Young Padawan

  • Members
  • Pip
  • 110 posts

Posted 18 April 2006 - 02:23 PM

i am making a button that changes 2 iframes at once. how can i do that?
something like this : <a href='x.html' target='one'><a href='y.html' target='two'> Bla Bla Bla </a></a>
so when i press : Bla.... the 2 iframes change into 'x.html' and 'y.html'
is it possible?

#2 DemetriusL

    Young Padawan

  • Members
  • Pip
  • 34 posts
  • Gender:Male
  • Location:United Kingdom

Posted 19 April 2006 - 05:09 PM

View PostFutingkiller, on Apr 18 2006, 08:23 PM, said:

i am making a button that changes 2 iframes at once. how can i do that?
something like this : <a href='x.html' target='one'><a href='y.html' target='two'> Bla Bla Bla </a></a>
so when i press : Bla.... the 2 iframes change into 'x.html' and 'y.html'
is it possible?

Umm... I ain't sure what you mean but I can help you make it, I know alot on Iframes. But what do you mean it changes into "2 Iframes"?

#3 coolaid

    P2L Jedi Master

  • Members
  • PipPipPipPip
  • 1,435 posts
  • Gender:Male
  • Interests:i wonder..

Posted 19 April 2006 - 06:06 PM

i know what he means, but i dont know how to do it, i dont think it's possible, maybe with javascript.

well anyway, he has two iframes, he wants links to be able to change the page that both iframes display

#4 tjl30

    Young Padawan

  • Members
  • Pip
  • 67 posts
  • Gender:Male
  • Location:MA
  • Interests:Graphic Design, Website layouts, Website scripting, movie editing, animation, snowboarding, sculpture, and drawing.

Posted 19 April 2006 - 06:47 PM

I wanted to do the same thing! Coolaid you said your self you "dont know how to do it" so why are you saing its not possible?

Anyways back to the quetion, I had the same quetion and I asked the helpfull 13dots community and got a reply from Holic. Holic said

holic said:

I assume you mean change the URL of two iFrames at the same time? In that case, you would do it like this:
<a href="URL1.html" target="target1" OnClick="parent.target2.location='URL2.html';">Click me!</a>
<iframe name="target1" src="index1.html"></iframe>
<iframe name="target2" src="index2.html"></iframe>
So, the link targets the 'target1' iframe, while the OnClick targets the 'target2' iframe. I hope that made sense
Origonal topic can been found [here]

Edited by tjl30, 19 April 2006 - 06:48 PM.


#5 Av-

    I Feel Left Out

  • Members
  • PipPipPipPip
  • 1,971 posts
  • Gender:Male
  • Location:10 ft. below sea level

Posted 19 April 2006 - 06:48 PM

Well, you can change onewith the a href tag, i think you can change the other with javascript.

Try this and see if it works.
<a href="frame1.php" target="frame1" onclick="document.frame2.src='frame2.php'"></a>

edit: nvm, he answered 1 minute faster, and mine suggestion would not have worked anyway :rolleyes:

Edited by Avalanche, 19 April 2006 - 06:49 PM.


#6 coolaid

    P2L Jedi Master

  • Members
  • PipPipPipPip
  • 1,435 posts
  • Gender:Male
  • Interests:i wonder..

Posted 19 April 2006 - 07:54 PM

Quote

Coolaid you said your self you "dont know how to do it" so why are you saing its not possible

i dont know how to do it, and i said 'think' its not possible. then i said maybe with javascript implying that with html alone its not possible (maybe).

but uhhh now we know it is possible with javascript :rolleyes:

#7 Futingkiller

    Young Padawan

  • Members
  • Pip
  • 110 posts

Posted 21 April 2006 - 10:49 AM

ok 10x a lot. i didn't know how to change a frame with javascript, but now i do :(
10x again

#8 CodeName.Dalit

    Young Padawan

  • Members
  • Pip
  • 8 posts

Posted 18 May 2006 - 09:40 AM

I still don't know how to do it.

this is my website


http://www.mark-glasgow.com/xp

I want the rollover-image on the left (the coffee) one, to change the main iframe to "contact.html" and the second_ iframe to "coffeebar.html"

help?

Edited by CodeName.Dalit, 18 May 2006 - 09:40 AM.


#9 Matthew.

    Official Spammer .Matt

  • Members
  • PipPipPipPip
  • 2,749 posts
  • Gender:Male
  • Location:England

Posted 18 May 2006 - 11:30 AM

Lets try reading? POst number four will do hat you want. :D ;)

http://www.pixel2life.com/forums/index.php...ndpost&p=134861

Edited by .Matt, 18 May 2006 - 11:31 AM.


#10 CodeName.Dalit

    Young Padawan

  • Members
  • Pip
  • 8 posts

Posted 18 May 2006 - 01:49 PM

no it doesnt.

it creates two whole new iframes, and elimates the rollover image.


I'm sure it works i just dont know how to implement it.

#11 CodeName.Dalit

    Young Padawan

  • Members
  • Pip
  • 8 posts

Posted 25 May 2006 - 12:04 PM

Finally got it!!

<a href="coffee.html" target="main" OnClick="parent.second.location='coffeebar.html';" onMouseOver="MM_swapImage('Image78','','invert/images/index_13.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="images/index_13.gif" name="Image78" width="109" height="58" border="0"></a>

Edited by CodeName.Dalit, 25 May 2006 - 12:15 PM.


#12 Futingkiller

    Young Padawan

  • Members
  • Pip
  • 110 posts

Posted 26 May 2006 - 02:17 PM

the 2 functions:
MM_swapImage () and
MM_swapImgRestore ()
have been created by you or dreamweaver?
just asking :)

Edited by Futingkiller, 26 May 2006 - 02:18 PM.


#13 CodeName.Dalit

    Young Padawan

  • Members
  • Pip
  • 8 posts

Posted 31 May 2006 - 01:21 PM

View PostFutingkiller, on May 26 2006, 02:17 PM, said:

the 2 functions:
MM_swapImage () and
MM_swapImgRestore ()
have been created by you or dreamweaver?
just asking :)
Dreamweaver. :D





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users