I need some help "moving" iframes

  • 1
  • Question
  • Updated 9 years ago
  • Answered
Hello everybody,

I am trying to work with iframes and they are giving me some trouble. I would like like my iframe to go to one specific place in the page. Do you get what I am saying? For example: I would like to have an iframe look at the middle of another website. Just say if you need more examples of what I am trying to do. It may not be able to even do it.

Thanks-Dan
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
  • excited!!!

Posted 9 years ago

  • 1
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Hi lambofgod,

Do you mean using an anchor with the iframe link?

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Hello Ellie,
yes I meant to use something like anchors. But my old brain kicked back in and used something else. So thank you for you suggestion. Also I would like to know (if you do) why does the iframe send my page all out of whack? And also under each iframe there is a yola logo, it's quite annoying.
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Hi lambofgod,

Can you show me your url?

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
atm it is http://www.newestfunny.com/ it is a brand new site. But I am still having trouble with the positioning. There is supposed to be a member login and a navigation menu. Only the login is showing.
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Hi lambofgod,

Did you change the width/height of the iframe? Maybe it's too small to show both the member login and navigation menu

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Yes I tried changing all the value's. Theyre two different iframes. One is for the login and the other is for the menu.
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Hi lambofgod,

After taking another look at your source code, I think I see the problem now. Both of your iframes are named "iframe". I would suggest changing that. Maybe that's what causing all the trouble.

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
erg your right! I should have noticed that. Thank you so much for pointing this out.
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Your welcome.

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Crap, now that I just added it, look what it did
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
Hi lambofgod,

If you're talking about the two links that lead right back to Yola, then I think I know the source. Your iframe named "navmenu" has a height of 3000px and it says no scroll. So I'm guessing, since this is an iframe and the source of your page, isn't very long, the result is that the second yola link came from the iframe and the huge height is because of the pixels.

Sorry am I making sense?

Ellie
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Sorry Ellie it took me so long to get back, had to mow the lawn. But the reason it's 3000px is to show the entire nav menu. For some reason it seems the two iframes are overlapping each other. Any idea's on that?
Photo of Ellie

Ellie

  • 38 Posts
  • 1 Reply Like
I think it's the position. Check this out:
Your first iframe (login) says: <!--style="position:absolute; top:40px; left:50px"-->
While your second iframe (nav menu) says: <!--style="position:absolute; top:50px; left:50px"-->

I think you have to change the first iframe position to something a little higher. That could be the reason why they're overlapping each other.

Ellie
Photo of Boomer

Boomer, Champion

  • 2055 Posts
  • 84 Reply Likes
Is this what you are trying to achieve, lambofgod:
http://hindsite.synthasite.com/framet...
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
LOL yes! How did you manage that? Also the nav menu is bigger.
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Ok I was able to recreate it. Very smart Boomer! Any ideas on how to kinda "raise up the menu" it seems to be hanging a little low.
Photo of Boomer

Boomer, Champion

  • 2055 Posts
  • 84 Reply Likes
1) Change the "position:absolute" to "position:relative"
2) Change the top and left px to "0" for both iframes
3) Adjust the navmenu iframe to (width="270px" height="300px")
4) Adjust the login iframe (width="270px" height="270px")
5) Place a text widget below the two iframes and hit enter a dozen times to move the Yola link down the page.
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Thank you so much Boomer and Ellie too. I appreciate it
Photo of Boomer

Boomer, Champion

  • 2055 Posts
  • 84 Reply Likes
Hey Dan,

On the page with the navmenu code.....(Not the page with the iframe code)
Try placing this code just above the navmenu code (in the same HTML widget)

<div align="left"><table cellpadding="0" cellspacing="0" width="600" height="400">
<tr>
<td valign="top" align="left"><div id="navmenu" style="position:absolute; left:0px; top:0px;">

Change the width and height to suit. This should shift the menu to the top left position on your menu page and it should then display the frame correctly.
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Thanks for the code Boomer. It looks great now.
Photo of Boomer

Boomer, Champion

  • 2055 Posts
  • 84 Reply Likes
Looks great Dan,
I see you now have 2 Yola links on the page.
Look at point 5 above to get rid of the one.
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
Awesome job Boomer! =)