function p_check() { if(document.getElementById('popup')!=null){ document.all['p_black'].style.width=document.body.clientWidth; document.all['p_black'].style.height=document.body.clientHeight; document.all['p_black'].style.top=document.body.scrollTop; document.all['p_black'].style.left=document.body.scrollLeft; if(popup.document.getElementById('p_x')!=null){ popup.p_getsize(); }; }; }; function p_pos(w,h) { if(document.getElementById('popup')!=null){ if(popup.document.getElementById('p_x')!=null){ if(document.body.clientWidth>w){ document.all['p_table'].style.left=(document.body.clientWidth-w-40)/2; document.all['p_table'].style.width=w+30; document.all['popup'].style.width=w; document.all['p_td1'].style.width=w-20; document.all['p_td4'].style.width=w-20; }else{ document.all['p_table'].style.left=document.body.scrollLeft-20; document.all['p_table'].style.width=document.body.clientWidth-40; document.all['popup'].style.width=document.body.clientWidth-20; document.all['p_td1'].style.width=document.body.clientWidth-40; document.all['p_td4'].style.width=document.body.clientWidth-40; }; if(document.body.clientHeight>h){ document.all['p_table'].style.top=document.body.scrollTop+(document.body.clientHeight-h-40)/2; document.all['p_table'].style.height=h+30; document.all['popup'].style.height=h; document.all['p_td2'].style.height=h-20; document.all['p_td3'].style.height=h-20; }else{ document.all['p_table'].style.top=document.body.scrollTop-20; document.all['p_table'].style.height=document.body.clientHeight-40; document.all['popup'].style.height=document.body.clientHeight-20; document.all['p_td2'].style.height=document.body.clientHeight-40; document.all['p_td3'].style.height=document.body.clientHeight-40; }; }; }; }; function p_show() { top.document.all['p_table'].style.visibility="hidden"; top.document.all['p_table'].style.visibility="visible"; p_getsize(); p_but(); }; function p_but() { document.all['p_prev'].style.left=document.body.scrollLeft; document.all['p_prev'].style.top=(document.body.clientHeight/2)+document.body.scrollTop-80; document.all['p_next'].style.left=document.body.scrollLeft+document.body.clientWidth-80; document.all['p_next'].style.top=(document.body.clientHeight/2)+document.body.scrollTop-80;}; function p_getsize() { top.p_pos(document.all['img'].width,document.all['img'].height); }; function p_hide() { top.document.all['p_table'].style.visibility="hidden"; top.document.all['p_black'].style.visibility="hidden"; }; function p_loading() { top.document.all['p_table'].style.visibility="hidden"; top.document.all['p_black'].style.visibility="visible"; }; Согласие на рекламу