Problem with iframe-integration of an external php-script

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
Post Reply
charliespeed
Posts: 21
Joined: Tue 7. Mar 2006, 17:13

Problem with iframe-integration of an external php-script

Post by charliespeed »

Hi all.

I've integrated an external php-Script within my site by using the iframe-solution:

Code: Select all

<script type="text/javascript">
function iFrameHeight() {
if(document.getElementById && !(document.all)) {
theFrame = document.getElementById('iframename');
h = theFrame.contentDocument.body.scrollHeight;
theFrame.style.height = h+15;
}else if(document.all) {
h = window.frames.iframename.document.body.scrollHeight;
document.all.iframename.style.height = h+15;
}
}
</script>
See it here: http://www.hebamme-in-hamburg.de/cms/in ... elle_kurse

Everything works fine for the 'first' page. But when you click a link to the details page of any training, the iframe doesn't recalculate it's height (of course?). So you end in a grey area and have to scroll upwards first before you see the information... :?

(try it yourself: click the "Informationen & Anmeldung" link for any item near the end of the page (e.g. GV-13/06)).

Since i'm not very experienced with javascript, can anyone help pls?

Thanks so far
Gunnar
User avatar
pico
Posts: 2595
Joined: Wed 28. Jul 2004, 18:04
Location: Frankfurt/M Germany
Contact:

Post by pico »

Hi

maybe try this Script http://www.hdk-online.de/iframe.phtml
Lieber Gott gib mir Geduld - ABER BEEIL DICH
Horst - find me at Musiker-Board
charliespeed
Posts: 21
Joined: Tue 7. Mar 2006, 17:13

Post by charliespeed »

very nice, but now a get scrollbar (within the iframe, not he page) :?: and only a part of the content is visible, not the whole list. this worked better with the old script. is there any solution to get rid of the scrollbars and display the whole list, with the content area being extended?

the result of the operation is still online:

http://www.hebamme-in-hamburg.de/cms/in ... elle_kurse
Post Reply