Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <iframe id='myFrame' />
- var src = 'data:text/html;charset=utf-8,' + encodeURIComponent(
- "<!doctype html><html><head></head><body><h1>Title</h1></body></html>");
- $('#myFrame').attr('src', src);
- $('#myFrame').contents().find('html').html('new template');
- var source = "<!doctype html><html><head></head><body><h1>Title</h1></body></html>";
- $('#myFrame').contents().find('html').html(source);
- $('#myFrame').contents().find('html').html('<body>Hi2</body>');
Add Comment
Please, Sign In to add comment