mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-10 11:26:47 +08:00
提交
This commit is contained in:
@@ -581,12 +581,20 @@
|
|||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
var scormIframe=document.getElementById('iframe-scorm');
|
var scormIframe=document.getElementById('iframe-scorm');
|
||||||
if (scormIframe) {
|
if (scormIframe) {
|
||||||
var iframeWin = scormIframe.contentWindow || scormIframe.contentDocument.parentWindow;
|
let iframeWin = scormIframe.contentWindow;
|
||||||
if (iframeWin.document.body) {
|
let iframeDoc = scormIframe.contentDocument || scormIframe.document;
|
||||||
scormIframe.height = iframeWin.document.documentElement.scrollHeight || iframeWin.document.body.scrollHeight;
|
|
||||||
}
|
let cHeight = Math.max(iframeDoc.body.clientHeight,iframeDoc.documentElement.clientHeight);
|
||||||
|
let sHeight = Math.max(iframeDoc.body. scrollHeight,iframeDoc.documentElement.scrollHeight);
|
||||||
|
let winHeight = iframeWin.document.documentElement.scrollHeight || iframeWin.document.body.scrollHeight;
|
||||||
|
|
||||||
|
let lheight = Math.max(cHeight, sHeight);
|
||||||
|
let finalHeight = Math.max(lheight, winHeight );
|
||||||
|
|
||||||
|
scormIframe.height =finalHeight;
|
||||||
|
console.log('scormIframe.height',scormIframe.height);
|
||||||
}
|
}
|
||||||
},500);
|
},1500);
|
||||||
|
|
||||||
},
|
},
|
||||||
loadMyScore(){
|
loadMyScore(){
|
||||||
|
|||||||
Reference in New Issue
Block a user