WebSite X5Help Center

 
Eduard B.
Eduard B.
User

Make iframe automatically adjust height according to the contents without using scrollbar  en

Автор: Eduard B.
Просмотрено 13638, Подписчики 1, Размещенный 0  

Hallo , first sorry for my bad english....

My problem is with HTML module. I wil show another page in my page with using iframe , but to full screen without scrooling . I try lot of ifrma codes also with iframe javascrit ,

like this code :

<iframe id="form-iframe" src="http://billandcoo.cz/CMS/kittens" style="margin:0; width:100%; height:150px; border:none; overflow:hidden;" scrolling="no" onload="AdjustIframeHeightOnLoad()"></iframe>

<script type="text/javascript">
function AdjustIframeHeightOnLoad() { document.getElementById("form-iframe").style.height = document.getElementById("form-iframe").contentWindow.document.body.scrollHeight + "px"; }
function AdjustIframeHeight(i) { document.getElementById("form-iframe").style.height = parseInt(i) + "px"; }
</script>

</div>

also I selected - marked on bottom the HTML module  "automatically enable height" and disable the "show scroling"

Alway is the same small height size.

Can you help me?

Thanks 

Eduard

Размещено
8 Ответы
Andre E
Andre E
Moderator
Лучший пользователь месяца EN

 <iframe src="http://billandcoo.cz/CMS/kittens" height="100%" width="100%" scrolling="no" </iframe>

set scrollbars off, enable auto height off, and height to 5800 in x5

Читать больше
Размещено От Andre E
 ‪ KolAsim ‪ ‪
 ‪ KolAsim ‪ ‪
Moderator
Лучший пользователь месяца ESЛучший пользователь месяца PT
Eduard B.
... ... My problem is with HTML module. I wil show another page in my page with using iframe , but to full screen without scrooling . I try lot of ifrma codes also with iframe javascrit ... ... ... ... 

(translated by google)
Your code works correctly only on the internet; for pages placed in your own web space, and not for pages placed on other servers.

(IT) - Il tuo codice funziona correttamente solo in internet; per pagine posizionate nel tuo stesso spazio web, e non per pagine posizionate su altri server.

 *

Buone Feste a Tutti ... ciao

Читать больше
Размещено От  ‪ KolAsim ‪ ‪
John S.
John S.
User

Hello Edouard

You could put the iframe in a container.

I have an example here : http://www.bramminginfo.dk/brm02/side-71.html

This shows a page from another server and with no scrollbar.

On the page is a html-object and a textbox beside this.

The "code" for the html-object is :

<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Hide iframe scrollbars</title>
<style>
#container{width: 900px; height: 650px; overflow: hidden;}
iframe{width: 918px; height: 658px;}
</style>
</head>

<body>
<div id="container">
<iframe src="https://www.admidio.org/"></iframe>
</div>
</body>
</html>

The formatting of the code is gone in the copy and paste process - you must do this yourself.

The html-object is checked for scrollbar ( it doesn't matter ) and set to 700 as height ( you can set it to fit your pagesize )

If the text had been longer there would appear a scrollbar so the whole text could be shown.

I have another example here : http://www.energifremtiden.dk/c4d/page-132.html

Beware - some sites will not be shown in an iframe. Google will not allow the page to be shown in an iframe for an example.

I hope you are helped.

Kind regards and a happy new year to all.

John S.

Читать больше
Размещено От John S.
John S.
John S.
User

Hello again Edouard

Just made a new example here : http://www.bramminginfo.dk/brm02/side-72.html

I made a page with no template and a menu in top.

Then the same code but for this site : http://calendarforum.dk/

Now it looks like the site is integrated in my site ( both are my sites ).

The calendarforum is made in ver 12.

It seems that all is functioning - even the rotate-able and zoom-able cube on the home-page can also be manipulated in the iframe.

I don't know if all this was what you asked for, but now I made it and I hope you will be inspired.

Please let me know when you have seen it - I want to remove it again.

Читать больше
Размещено От John S.
John S.
John S.
User

Hello Eduard

A kind of response would be appreciated ????

Читать больше
Размещено От John S.
Eduard B.
Eduard B.
User
Автор

Hallo sorry I was not here long time....

Thanks for help , My problem is if I use in 1 line 3 html blocks and wil show 3 diferent pages in my page with iframe or embend or similar code ....

Ewrithing wil be fine but on Ipad show with no 100 percent width in block ...

yo can se it ot the bottom on this page: http://www.billandcoo.cz/home.html

News , Litters , Info

The idea was use some live edit cms page show on my page with transparent background . The orginal dynamic content from websitex5 its not good to use like cms and I m now to searching some CMS to integrate in this software to use for future websites....

I found one : WonderCMS '' https://www.wondercms.com/ '' and now I work to use it direct in Websitex5 software or search some code to show content full cms page in my or better only content from this CMS.

Wil be fine to have summer editor '' https://summernote.org/ '' for dynamic content..

Sorry for my bad english....

Читать больше
Размещено От Eduard B.
 ‪ KolAsim ‪ ‪
 ‪ KolAsim ‪ ‪
Moderator
Лучший пользователь месяца ESЛучший пользователь месяца PT
Eduard B.
... ... ...yo can se it ot the bottom on this page: http://www.billandcoo.cz/home.html News , Litters , Info ... ... ...

I do not see the dynamic IFRAME code applied ...

.

Читать больше
Размещено От  ‪ KolAsim ‪ ‪
Eduard B.
Eduard B.
User
Автор

Yes at the moment I use the dynamic content from the websitex5 because no one iframe code worked for it.....

At the moment I try to integrate some flat CMS to the html block and work fine . With iframe have problems in some intrnet explorers with full width , and Im on search some alternative to show on the home page in smal window show top or full of pege A , page B , Page C like on  http://www.billandcoo.cz/home.html

Читать больше
Размещено От Eduard B.