mirror of
https://github.com/niklasvh/html2canvas.git
synced 2023-08-10 21:13:10 +03:00
fixed firefox iframe permission error
This commit is contained in:
parent
343b86705f
commit
1ba911912d
@ -111,18 +111,23 @@ _html2canvas.Preload = function( options ) {
|
||||
|
||||
var contents = _html2canvas.Util.Children(el),
|
||||
i,
|
||||
contentsLen = contents.length,
|
||||
background_image,
|
||||
src,
|
||||
img,
|
||||
elNodeType = false;
|
||||
|
||||
// Firefox fails with permission denied on pages with iframes
|
||||
try {
|
||||
var contentsLen = contents.length;
|
||||
for (i = 0; i < contentsLen; i+=1 ){
|
||||
// var ignRe = new RegExp("("+this.ignoreElements+")");
|
||||
// if (!ignRe.test(element.nodeName)){
|
||||
getImages(contents[i]);
|
||||
// }
|
||||
}
|
||||
}
|
||||
catch( e ) {}
|
||||
|
||||
|
||||
// }
|
||||
try {
|
||||
@ -145,7 +150,6 @@ _html2canvas.Preload = function( options ) {
|
||||
// TODO add multi image background support
|
||||
|
||||
if (/^(-webkit|-o|-moz|-ms|linear)-/.test( background_image )) {
|
||||
// if (background_image.substring(0,7) === "-webkit" || background_image.substring(0,3) === "-o-" || background_image.substring(0,4) === "-moz") {
|
||||
|
||||
img = _html2canvas.Generate.Gradient( background_image, _html2canvas.Util.Bounds( el ) );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user