...

View Full Version : Problem with link to refresh iframe contents.



HHawk
12-05-2005, 06:06 PM
Hi guys...

I have a "small" problem concerning my website.
Since my native language isn't English, I provided a screenshot to show you what problem I am having with my website.

Take a look at this screenshot (http://www.linkplanet.nl/example.jpg).

The GREEN square indicates an iframe.
The RED arrows are buttons, which (when clicked) should refresh the iframe with the appropiate content concerning that link.

Anyways; I am having a hard trouble to make it work, like I want. Probably I am overlooking something.

I simply can't manage to make the links (e.g. "nieuws" or "MSN") refresh the iframe with the correct contents.

I hope you can understand what I mean and again I am sorry if I can't make myself clear on what I mean.

Hopefully someone can help me out.

Programs used:

- Photoshop (and Imageready)
- Dreamweaver (and Fireworks)

Thanks.

_Aerospace_Eng_
12-05-2005, 06:11 PM
Give the iframe a name

<iframe src="somepage.html" name="content"></iframe>
then set the target of your links to the name of the iframe

<a href="someotherpage.html" target="content">Some other page</a>

HHawk
12-05-2005, 06:13 PM
Give the iframe a name

<iframe src="somepage.html" name="content"></iframe>
then set the target of your links to the name of the iframe

<a href="someotherpage.html" target="content">Some other page</a>


Damn that's it? Man I will try that immeadently; I have been bothered with this the last couple of hours.

Thanks in advance, I will respond if it works (or not). :) :)

HHawk
12-05-2005, 06:21 PM
It worked!

Damn, now I really feel stupid that I didn't see this one coming.
Oh well, blame it on the tough weekend I had. :S

Thanks again mate.
Highly appreciated.

HHawk
12-05-2005, 07:24 PM
Okay it seems to work perfectly in Internet Explorer.
But it doesn't work with Mozilla Firefox...?

In Firefox it opens a complete new page, instead of using the iframe.
Any ideas on how to solve that as well?

Thanks again in advance.

_Aerospace_Eng_
12-05-2005, 07:49 PM
It should work in Firefox to. Post a link to your page, you may have some errors causing the problem, then again this could be a setting in your own browser.

HHawk
12-05-2005, 07:55 PM
Okay, here is a link to my website.

E.g. click on "NIEUWS" and / or "MSN".

In Internet Explorer it works without problems (opens in the frame, like it should), but in Mozilla Firefox it opens it in a new blank page?

Thanks for looking at it.

_Aerospace_Eng_
12-05-2005, 08:26 PM
Lose the underscore in the name of the iframe. Make sure you change your targets as well. A name and/or id should not begin with an underscore it is invalid.

HHawk
12-05-2005, 08:35 PM
Bleh and I thought I was trying to be original with the underscore... :S

Thanks again mate. :)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum