Buttons being targeted to and IFrame, how is this done?

liunx

Guest
greetings.......<br />
<br />
ive never used buttons before in any sites ive always used a DHTML slide menu or something similar, or just regular links, i know how to target links to an iframe.<br />
<br />
i made a bunch of buttons that im going to put in a navigation bar, and i want the buttons to load in the I-frame.<br />
<br />
so first i have to make the button a link<br />
<br />
if i remember correctly<br />
<br />
its <br />
<br />
<a href=http://www.htmlforums.com/archive/index.php/"http://www.blah.com"><img src="http://www.blahpicture.com"></a><br />
to make a button<br />
i could be wrong though :monkey:<br />
<br />
now what has to be done to target it for the iframe?<br />
<br />
<a href=http://www.htmlforums.com/archive/index.php/"http://www.blah.com" target="iframe"><br />
<img src=http://www.htmlforums.com/archive/index.php/"http://www.blahpicture.com"><br />
</a><br />
<br />
would that be the proper way?<!--content-->what, so an image, not a button?<br />
<br />
hmmm.<br />
<br />
oh well.<br />
<br />
yeah, that looks right to me, just put the <a> tag around the image with the target="" in there and you're set<!--content-->that's correct.<br />
<br />
make sure you put alt tags in your img tags!<!--content-->did you ever thin of trying our a few different ways b4 posting? :newbie: no im just kidding but you should try that some time.<!--content-->13, even if Collado hasn't tried a few things, the information is handy. Not everyone knows everything there is to know about web design coding. I'm not entirely sure how to target for an iFrame. I'm just going on what little I know of frames. <br />
<br />
Collado, don't forget to name/id the iFrame and use that as the target. Like this:<br />
<br />
iFrame Code<br />
<iframe id="framename" name="framename" width="100%" height="100% scrolling="auto" frameborder="0" src=http://www.htmlforums.com/archive/index.php/"filename.htm"></iframe><br />
<br />
Or however you want your iFrame to be set up for size, scrolling, etc.<br />
<br />
Link Code<br />
<a href=http://www.htmlforums.com/archive/index.php/"filenam2.htm" target="framename"><img src="button.jpg" alt="Link Name"></a><br />
<br />
Your iFrame source is the first page that people will see when the page loads up, an introduction to the section/site or whatever. I'm not sure if iFrames are treated the same as any other frame or not, but do remember that it might not work on all browsers.<br />
<br />
*lol* And if that code doesn't work for you, let me know, will you? It works on some of my pages, but not others. I think the fault is in the external pages, but don't quote me on it. It'll be nice to have a double-check. Thanks.<br />
<br />
Peg<!--content-->
 
Back
Top