bnbweb/themes/vr/portal/js/top.js
2022-11-14 23:49:28 +08:00

59 lines
1.5 KiB
JavaScript
Executable File

// JavaScript Document
function open_layer_detail(div_name,width,height){
if(width==''){
width=0;
}
if(height==''){
height=0;
}
$.blockUI({
message:$('#'+div_name),
css:{
cursor:'default',
width: width + 'px',
height:height+ 'px',
padding:'0px',
top:($(window).height()-height)/2 + 'px',
left:($(window).width()-width)/2 + 'px'
}
});
}
function open_loading_status(loading_name){
width=$('#'+loading_name).css('width').replace("px","");
height=$('#'+loading_name).css('height').replace("px","");
$.blockUI({
message:$('#'+loading_name),
css:{
cursor:'default',
border:'',
backgroundColor:'',
width: width + 'px',
height:height+ 'px',
padding:'0px',
top:($(window).height()-height)/2 + 'px',
left:($(window).width()-width)/2 + 'px'
}
});
}
function close_layer_detail(){
$.unblockUI();
}
function close_top_layer_detail(){
top.$.unblockUI();
}
//建立執行的div
$(function(){
jQuery.browser = {};
(function () {
jQuery.browser.msie = false;
jQuery.browser.version = 0;
if (navigator.userAgent.match(/MSIE ([0-9]+)\./)) {
jQuery.browser.msie = true;
jQuery.browser.version = RegExp.$1;
}
})();
$('body').prepend("<span id='iframe_string'></span>");
$('body').prepend('<div id="waiting_action" style="display:none;text-align:center;position: absolute;z-index: 99998;color:#FFF;font-size:12px;border:0px;"><img src="themes/vr/images/loading_big.gif" hspace="2" align="absmiddle"/><br><img src="themes/vr/images/loading_text.png" hspace="2" align="absmiddle"/></div>');
});
//end