1
I need to generate a iframe
dynamic by clicking a button on a div
for a mobile app only when I try to load it iframe
using the method Onload in the Body it does not automatically load and only when I refresh the page (F5).
Follow part of my code:
<script>
function Map()
{
var retorno;
var largura;
var altura;
largura = ($(document).width()) - 20;
altura = ($(document).height()) -200;
retorno = '<iframe src="http://iframeasercarregado" frameborder="0" scrolling="auto" width="' + largura + '" height="' + altura + '"></iframe>';
$('.map').html(retorno);
}
</script>
<html>
<body onLoad="Map();">
<div class="map"></div>
</body>
</html>
Ever heard of @media queries of CSS ?
– Ivan Ferrer
Never heard of no...
– Renan Maldonado Marques
So, do a search, which will help you a lot for mobile versions.
– Ivan Ferrer
Take a look at this answer, see if it helps you: http://answall.com/questions/82543/n%C3%A3o-rodar-iframe-enquanto-n%C3%A3o-clique/82582#82582
– Ivan Ferrer
You want to always make iframe responsive or the issue is iframe loading?
– Rodrigo Santos
I want to make Iframe always responsive and carry it Rodrigo
– Renan Maldonado Marques