//初始化导航背景,iframe容器
function fnDaoHangBg()
{
var h = fnGetHeight(),w = fnGetWidth();//获取背景窗口大小
if(!$('pDaoHangBg'))
{
var p = $C('p');//创建背景蒙板
p.id = 'pDaoHangBg';
p.style.backgroundColor = 'black';
p.style.position = 'absolute';
p.style.filter = 'alpha(opacity=80)';
p.style.opacity = '.80';
p.style.zIndex = 100001;
p.style.left = 0;
p.style.top = 0;
p.style.width = w+'px';
p.style.height= h+'px';
document.body.appendChild(p);
}
if(!$('pDaoHangBgIframe'))
{
var iframe;
iframe = this.$C('IFRAME');//创建蒙板内的内嵌iframe容器,用于嵌入显示其他网页
iframe.id = 'pDaoHangBgIframe';
iframe.frameBorder = '0';
iframe.scrolling = "no";
iframe.style.overflow = 'hidden';
iframe.allowTransparency = 'true';
iframe.style.display = 'none';
iframe.style.width = w+'px';//800
iframe.style.height = h+'px';//620
iframe.style.marginTop = '75px';//800
$('pDaoHangBg').appendChild(iframe);
}
if(!$('pDaoHangBgClose'))
{
var p = $C('p');//创建关闭按钮在蒙板上
p.id = 'pDaoHangBgClose';
p.style.position = 'absolute';
p.style.backgroundImage='url(images/closb.gif)';
p.style.zIndex = 100003;
p.style.right = 10;
p.style.top = 20;
p.style.width = '82px';
p.style.height= '30px';
p.title='关闭';
p.style.cursor='hand';
p.Onclick=function(){//点击时间 ,关闭蒙板
fnDaoHangBgClose();
};
$('pDaoHangBg').appendChild(p);
}
$('pDaoHangBgIframe').style.display='block';
$('pDaoHangBg').style.display='block';
}
//关闭蒙板
function fnDaoHangBgClose()
{
if(!$('pDaoHangBg')){return;}
if(!$('pDaoHangBgIframe')){return;}
$('pDaoHangBgIframe').src='';
$('pDaoHangBgIframe').style.display='none';
$('pDaoHangBg').style.display='none';
}
//调用,内嵌url
function fnDaoHangBgShow(url)
{
fnDaoHangBg();
$('pDaoHangBgIframe').src=url;
}