PDA

View Full Version : [HELP] Iframes [HELP]



Liburd
14-05-2008, 12:16 PM
Ok Im having trouble with my Iframes Ive made them expandable but they are not expanding :s and the sub navigation just messes up

http://habboinfo.co.uk/uk/

+rep for help!

Liburd
14-05-2008, 12:46 PM
bump [sorry] lol

DUB
14-05-2008, 12:49 PM
EDIT: my bad, well it seems no page is even loading in the sub nav iframe anyway so..

DUB
14-05-2008, 01:07 PM
couldn't edit previous post..

But erm, you can try this though...

In your header put:

<script language="JavaScript">
function iframelol() {
if(document.getElementById && !(document.all)) {
h = document.getElementById('content').contentDocument .body.scrollHeight;
document.getElementById('content').style.height = h;
}
else if(document.all) {
h = document.frames('content').document.body.scrollHei ght;
document.all.content.style.height = h;
}
}
</script>

Then in your body tag you need to load the function so put:


<body onLoad="iframelol()">


Then just put your iframe tag where you want it to go for e.g:


<iframe src="homepage.html" width=XX scrolling=no frameborder=0 id="content"; ></iframe>



haven't tested it, but it should work

Liburd
14-05-2008, 01:23 PM
K it works in IE but not in firefox :S

Want to hide these adverts? Register an account for free!