|
|
|
|
@ -142,9 +142,15 @@ $htmlHeadXtra[] = '<script type="text/javascript"> |
|
|
|
|
document.getElementById("mainFrame").style.height = ((docHeight-(parseInt(HeaderHeight)+parseInt(FooterHeight)))+60)+"px"; |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
function insertIt() { |
|
|
|
|
var _y = document.getElementById("framediv"); |
|
|
|
|
var _x = window.frames[0].document.body.innerHTML; |
|
|
|
|
_y.innerHTML = _x |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Fixes the content height of the frame |
|
|
|
|
window.onload = function() { |
|
|
|
|
updateContentHeight(); |
|
|
|
|
//updateContentHeight(); |
|
|
|
|
'.$js_glossary_in_documents.' |
|
|
|
|
} |
|
|
|
|
--> |
|
|
|
|
@ -168,12 +174,13 @@ echo "<div align=\"center\">"; |
|
|
|
|
$file_url_web = api_get_path(WEB_COURSE_PATH).$_course['path'].'/document'.$header_file.'?'.api_get_cidreq(); |
|
|
|
|
echo '<a href="'.$file_url_web.'" target="_blank">'.get_lang('_cut_paste_link').'</a></div>'; |
|
|
|
|
//echo '<div>'; |
|
|
|
|
|
|
|
|
|
echo '<div id="framediv">'; |
|
|
|
|
if (file_exists($file_url_sys)) { |
|
|
|
|
echo '<iframe border="0" frameborder="0" scrolling="auto" style="width:100%;" id="mainFrame" name="mainFrame" src="'.$file_url_web.'&rand='.mt_rand(1, 10000).'"></iframe>'; |
|
|
|
|
echo '<iframe border="0" onload="insertIt();" frameborder="0" scrolling="auto" style="width:100%;" id="mainFrame" name="mainFrame" src="'.$file_url_web.'&rand='.mt_rand(1, 10000).'"></iframe>'; |
|
|
|
|
} else { |
|
|
|
|
echo '<frame name="mainFrame" id="mainFrame" src=showinframes.php?nopages=1 />'; |
|
|
|
|
echo '<frame name="mainFrame" onload="insertIt();" id="mainFrame" src=showinframes.php?nopages=1 />'; |
|
|
|
|
} |
|
|
|
|
echo '</div>'; |
|
|
|
|
|
|
|
|
|
//echo '</div>'; |
|
|
|
|
|
|
|
|
|
|