Skip to content
Advertisement

Tag: iframe

Prevent parent page from scrolling when mouse is over embedded iframe in Firefox

…without limiting the scroll inside the iframe or the need to specifically name/tag all scrollable elements. Imagine google maps widget embedded in parent page. When you zoom in the widget you don’t want the parent page to scroll, obviously. I thought an answer to my previous question solved the problem: While scrolling inside an iframe, the body doesn’t know anything

Prevent PDF auto download by idm using pdf.js

I’m using PDF.Js to embed PDF file for preview, and I removed the script of download and open files from the viewer.js , but when I test the page and PDF file try to show, the Internet Download Manager download it and abort the preview .. after search I found that using object instead of iframe may solve the problem,

Set URL to load iframe in a Django template

I want to load an iframe into a Django template. The template is getting loaded correctly, but in place of the iframe, the template itself is getting embedded inside the parent template. The code relevant is given below: testgame.html is a file located in the same directory as this HTML template, but it doesn’t load. In its place, the parent

Embedded YouTube videos won’t replay

Strange one: embedded YouTube videos, once played (either by clicking ‘play’ or autoplaying on page load) will not play again. I’m using the standard iFrame embed copied straight from YouTube. This happens with several different short videos and across all browser/OS combinations I’ve tested (Chrome/Safari/Firefox/IE on Windows/Mac). Here’s the code: and you can see it in action at this fiddle.

Creating an iframe with given HTML dynamically

I’m trying to create an iframe from JavaScript and fill it with arbitrary HTML, like so: I would expect iframe to then contain a valid window and document. However, this isn’t the case: > console.log(iframe.contentWindow); null Try it for yourself: http://jsfiddle.net/TrevorBurnham/9k9Pe/ What am I overlooking? Answer Setting the src of a newly created iframe in javascript does not trigger the

Advertisement