itsinevitable
05-03-2005, 05:20 AM
Okay- My friend has WordPress, and she needs a CSS layout. I decided to help, and try to code it for her, because well- I wanted to help, and I like coding. Anyway, I was trying to link the iframe CSS onto the main page, but it doesn't work. Can somebody tell me what's wrong with the code? Here's the code.
<div id="iframe">- That's the id for the iframe.
#iframe
{iframe name="iframe"
src="http://"
scrolling="auto"
frameborder="0"
style="position:absolute; left:240px; top:480px; width:527px; height:425px;}
^ I think that might be the problem. The iframe css, but I don't know. =/
erictheman
05-03-2005, 06:42 AM
Okay, i don't know what css you're using, but that's completely wrong. and you shouldn't use css for an iframe.
Fix your code up because there's no help to be offered here.
Paysan Barbare
05-03-2005, 07:54 AM
it should be like this:
#iframe
{
position:absolute;
left:240px;
top:480px;
width:527px;
height:425px;
}
remember that a css is only for coding th style, so don't use the keyword "style" in the css
you are tring to make a div pretent to be an iframe.
instead of this...
<div id="iframe">
you should have this...
<iframe src="http://" name="myiframe" frameborder="0" id="myiframestyle></iframe>
and instead of this...
#iframe
{iframe name="iframe"
src="http://"
scrolling="auto"
frameborder="0"
style="position:absolute; left:240px; top:480px; width:527px; height:425px;}
you should have this...
#myiframestyle {
position:absolute;
left:240px;
top:480px;
width:527px;
height:425px;}
(use whatever ID names you desire, that is just for example purposes.
itsinevitable
05-04-2005, 02:23 AM
Okay, i don't know what css you're using, but that's completely wrong. and you shouldn't use css for an iframe.
Fix your code up because there's no help to be offered here.
I'm trying to code a layout in CSS. No need to be rude about it. And plus, other people can help me, so it's not like you're the only one that can help.
itsinevitable
05-04-2005, 02:27 AM
it should be like this:
#iframe
{
position:absolute;
left:240px;
top:480px;
width:527px;
height:425px;
}
remember that a css is only for coding th style, so don't use the keyword "style" in the css
Thanks, that helped.
you should have this...
<iframe src="http://" name="myiframe" frameborder="0" id="myiframestyle></iframe>
Ahhh. I see what you mean. Hmmm... But when I show it, I just use that code or should I add the iframe source also?
MaGiCSuN
05-04-2005, 08:08 AM
that is the iframe ...
inside the iframe a page opens ... wich url should be in this:
src="http://"
an iframe is an inline frame that displays whole other pages inside a page ...
css doesn't make tags, it styles them and formats them, that's why you need the src="" info in the <iframe> tag and not in the css part :)
you add this in your css:
#frame {
position:absolute;
left:240px;
top:480px;
width:527px;
height:425px;}
then add this on the place where you want the iframe to appear:
<iframe src="http://" name="frame" frameborder="0" id="frame"></iframe>
and change the url to the url of the page you want to appear inside the iframe when loading the page.
then when you add links on the page where the <iframe> tag is aswell, you need to target them with target="frame"
if you keep those names the same (name, target) then it should work :)
Love,
Mirna
place that iframe tag where you want the iframe to appear.
yes, you will have to enter the true value for the src value for whatever page you want to appear inside the iframe area at startup.
itsinevitable
05-05-2005, 04:02 AM
Mmkay. Thanks, you guys helped a lot. :)
no worries. good luck! :hamster: