=?UTF-8?q?In=20FF=20the=20<object>=20attriute=20needs=20to=20be?= =?UTF-8?q?=20from=20type=20'data'=20and=20not=20'src'.=0AChrome=20seems?= =?UTF-8?q?=20to=20be=20happy=20with=20'src'.=20This=20commit=20changes=20?= =?UTF-8?q?it=20back=20to=20'data'.?=

This commit is contained in:
Bjoern Gruening
2014-10-18 18:38:04 -04:00
parent 0e8289d47f
commit 4eaba38f2e
@@ -145,40 +145,18 @@ if ( ${ password_auth_jsvar } ) {
// If that is successful, load the notebook
success: function(){
//Append an object to the body
$('body').append(
$('<object/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
}).append(
// And an embed to the object
$('<embed/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
})
)
);
$('body').append('<object data="${ notebook_access_url }" height="100%" width="100%">'
+'<embed src="${ notebook_access_url }" height="100%" width="100%"/></object>'
)
},
error: function(jqxhr, status, error){
if(${ password_auth_jsvar } && !${ apache_urls_jsvar }){
$('body').append("Error, could not automatically authorize you. Your"
+ " password is: ${ notebook_pw }<br/>Ask your administrator"
+ " to set apache_urls = True to make this go away");
$('body').append(
$('<object/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
}).append(
// And an embed to the object
$('<embed/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
})
)
);
$('body').append('<object data="${ notebook_access_url }" height="100%" width="100%">'
+'<embed src="${ notebook_access_url }" height="100%" width="100%"/></object>'
)
}else{
var error_msg = "<h1>Error " + status
+ "</h1>Could not connect to IPython Notebook: "
@@ -195,20 +173,9 @@ if ( ${ password_auth_jsvar } ) {
else {
// Not using password auth, just embed it to avoid content-origin issues.
$( document ).ready(function() {
$('body').append(
$('<object/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
}).append(
// And an embed to the object
$('<embed/>', {
src: '${ notebook_access_url }',
height: '100%',
width: '100%'
})
)
);
$('body').append('<object data="${ notebook_access_url }" height="100%" width="100%">'
+'<embed src="${ notebook_access_url }" height="100%" width="100%"/></object>'
)
});
}
</script>