Not load video embedded with iframe when detect a mobile device
In my webpage there is an iframe that embeds a video (vimeo) with a jquery
scripts that render the video fullscreen.
The problem is that in mobile devices (specially the apple devices) with a
full-witdh video is impossible to push over a link that is obviously over
the video player.
My solution is hide the video with a jquery script
$('#vimeo').css('display', 'none');
$('#image_video').css('display', 'block');
and show an image instead of video that link directly to the vimeo page.
In this way i suppose that also if the video is hidden it will be load in
background anyway and for mobile internet connection this is a waste.
My question is, is there a way to prevent the loading of the iframe?
I hope I explained myself. I'm sorry for my english.
No comments:
Post a Comment