Widget:Charsheet: различия между версиями
Материал из Ролевой сервер "tales.pw"
Xunto (обсуждение | вклад) |
Xunto (обсуждение | вклад) |
||
| Строка 2: | Строка 2: | ||
width="100%" | width="100%" | ||
frameborder='no' | frameborder='no' | ||
| + | onload="AdjustIframeHeightOnLoad()" | ||
/> | /> | ||
| + | |||
| + | <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> | ||
Версия 22:42, 25 июля 2019
<iframe src="https://test.tales.pw/{name}"
width="100%" frameborder='no' onload="AdjustIframeHeightOnLoad()"
/>
<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>