function intVal(tag){return parseInt(document.getElementsByName(tag).item(0).value);}
function getObj(tag){return document.getElementsByName(tag).item(0);}
function getStrVal(tag){return document.getElementsByName(tag).item(0).value.toString();}
function bd_red(pg,vw){if(vw>0) document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+pg.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId'); else document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+pg.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}
function sr_r(strPage,strPageVal){getObj('hidCurrPg').value=strPage;document.location='body.aspx?z='+getObj('hidZoom').value.toString()+'&p='+strPage+'&v='+getObj('hidView').value.toString()+'&uid='+getStrVal('hidUserId');}
function sr_rl(strPage,strLang,AC){if(AC==1)window.top.location='../'+strLang+'/default.aspx?z='+getStrVal('hidZoom')+'&p='+strPage+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')+'&AC='+getStrVal('hidAC'); else window.top.location='../'+strLang+'/body.aspx?z='+getStrVal('hidZoom')+'&p='+strPage+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');}
function nv_sr_click(){if(getStrVal('hidLastEnt')=='1' && getStrVal('txtSearch')!='SEARCH for...'){document.location='search.aspx?s='+getStrVal('txtSearch')+'&rp=1&z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}else{var sPG='';var iPG=1;var iPT=intVal('hidPageTot');sPG=getStrVal('update_page_number');if(sPG=='1')iPG=1; else if(sPG=='2')iPG=2; else iPG=intVal('update_page_number');if(iPG<0||iPG>iPT)iPG=1;document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+iPG.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');getObj('hidCurrPg').value=iPG;getObj('update_page_number').value=sPG}}
function nv_zout_click(){if(1<intVal('hidZoom')){getObj('hidZoom').value=intVal('hidZoom')-1;zoomstate.src='images/zoom_'+getStrVal('hidZoom')+'.gif';document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}}
function nv_zout_over(){if(1<intVal('hidZoom')){getObj('zoomout').src='images/zoom_less_on.gif'}}
function nv_zout_down(){if(1<intVal('hidZoom')){getObj('zoomout').src='images/zoom_less_down.gif'}}
function nv_zout_up(){if(parent.m_current_zoom=='size_01'){getObj('zoomout').src='images/zoom_less_off.gif'}else{getObj('zoomout').src='images/zoom_less_on.gif'}}
function nv_oneup_click(){getObj('hidView').value='1';document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}
function nv_sec_onChange(){var iPG=intVal('sections');document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+iPG.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}
function nv_twoup_click(){getObj('hidView').value='2';var iPG=intVal('hidCurrPg');if(iPG!=1){var ihPG=(iPG % 2);iPG=iPG-ihPG;}getObj('hidCurrPg').value=iPG;if(iPG==1)getObj('update_page_number').value='1';else if(iPG==0)getObj('update_page_number').value='2';else getObj('update_page_number').value=iPG;document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+iPG.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}
function nv_zin_click(){if(intVal('hidZoom')<5){getObj('hidZoom').value=intVal('hidZoom')+1;getObj('zoomstate').src='images/zoom_'+getStrVal('hidZoom')+'.gif';document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}}
function nv_fpg_out(){getObj('first').src='images/arrow_first_off.gif';try{getObj('first2').src='images/arrow_first_off.gif'}catch(e){}}
function nv_fpg_up(){if(1<intVal('hidCurrPg')){getObj('first').src='images/arrow_first_over.gif';try{getObj('first2').src='images/arrow_first_over.gif'}catch(e){}}}
function nv_fpg_down(){if(1<intVal('hidCurrPg')){getObj('first').src='images/arrow_first_down.gif';try{getObj('first2').src='images/arrow_first_down.gif'}catch(e){}}}
function nv_fpg_over(){if(1<intVal('hidCurrPg')){getObj('first').src='images/arrow_first_over.gif';try{getObj('first2').src='images/arrow_first_over.gif'}catch(e){}}}
function nv_fpg_click(){document.location='body.aspx?z='+getStrVal('hidZoom')+'&p=1&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId')}
function nv_prpg_out(){getObj('prev').src='images/arrow_previous_off.gif';try{getObj('prev2').src='images/arrow_previous_off.gif'}catch(e){}}
function nv_prpg_up(){if(1<intVal('hidCurrPg')){getObj('prev').src='images/arrow_previous_over.gif';try{getObj('prev2').src='images/arrow_previous_over.gif'}catch(e){}}}
function nv_prpg_down(){if(1< intVal('hidCurrPg')){getObj('prev').src='images/arrow_previous_down.gif';try{getObj('prev2').src='images/arrow_previous_down.gif'}catch(e){}}}
function nv_prpg_over(){if(1< intVal('hidCurrPg')){getObj('prev').src='images/arrow_previous_over.gif';try{getObj('prev2').src='images/arrow_previous_over.gif'}catch(e){}}}
function nv_prpg_click(){if(1<intVal('hidCurrPg')){var iPG=intVal('hidCurrPg')-intVal('hidView');if(iPG<1)iPG=1;if(iPG!=1 && getStrVal('hidView')=='2'){var ihPG=(iPG % 2);iPG=iPG-ihPG;}getObj('hidCurrPg').value=iPG;document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');var iPG=intVal('hidCurrPg');if(iPG==1)getObj('update_page_number').value='1';else if(iPG==0)getObj('update_page_number').value='2';else getObj('update_page_number').value=iPG}}
function nv_next_out(){getObj('next').src='images/arrow_next_off.gif';try{getObj('next2').src='images/arrow_next_off.gif'}catch(e){}}
function nv_next_over(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){getObj('next').src='images/arrow_next_over.gif';try{getObj('next2').src='images/arrow_next_over.gif'}catch(e){}}}
function nv_next_down(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){getObj('next').src='images/arrow_next_down.gif';try{getObj('next2').src='images/arrow_next_down.gif'}catch(e){}}}
function nv_next_click(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){var iPG=intVal('hidCurrPg')+intVal('hidView');if(iPG!=1 && intVal('hidView')=='2'){var ihPG=(iPG % 2);iPG=iPG-ihPG;}getObj('hidCurrPg').value=iPG;document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidCurrPg')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');var iPG=intVal('hidCurrPg');if(iPG==1)getObj('update_page_number').value='1'; else if(iPG==0)getObj('update_page_number').value='2'; else getObj('update_page_number').value=iPG}}
function nv_lpg_out(){getObj('last').src='images/arrow_last_off.gif';try{getObj('last2').src='images/arrow_last_off.gif'}catch(e){}}
function nv_lpg_up(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){getObj('last').src='images/arrow_last_over.gif';try{getObj('last2').src='images/arrow_last_over.gif'}catch(e){}}}
function nv_lpg_down(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){getObj('last').src='images/arrow_last_down.gif';try{getObj('last2').src='images/arrow_last_down.gif'}catch(e){}}}
function nv_lpg_over(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){getObj('last').src='images/arrow_last_over.gif';try{getObj('last2').src='images/arrow_last_over.gif'}catch(e){}}}
function nv_lpg_click(){if(intVal('hidCurrPg')<=intVal('hidPageTot')-intVal('hidView')){document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+getStrVal('hidPageTot')+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');getObj('hidCurrPg').value=getObj('hidPageTot').value;var iPG=intVal('hidCurrPg');if(iPG==1)getObj('update_page_number').value='1';else if(iPG==0)getObj('update_page_number').value='2';else getObj('update_page_number').value=iPG}}
function nv_go_click(){var sPG='';var iPG=1;var iPT=intVal('hidPageTot');sPG=getStrVal('update_page_number');if(sPG=='1')iPG=1;else if(sPG=='2')iPG=2;else iPG=intVal('update_page_number');if(iPG<0||iPG>iPT)iPG=1;document.location='body.aspx?z='+getStrVal('hidZoom')+'&p='+iPG.toString()+'&v='+getStrVal('hidView')+'&uid='+getStrVal('hidUserId');getObj('hidCurrPg').value=iPG;getObj('update_page_number').value=sPG}
function bd_set(pg,vw,z){getObj('hidCurrPg').value=pg;document.getElementsByName('hidView').item(0).value=vw;document.getElementsByName('hidZoom').item(0).value=z;var iPG=parseInt(pg);var iSP=parseInt('1');if(iSP<1)iPG=iPG-1;if(iSP<0)iPG=iPG-1;if(iPG<1){var t='i';if(iPG==0 && iSP<0)	t+='i'; document.getElementsByName('update_page_number').item(0).value=t;}else document.getElementsByName('update_page_number').item(0).value=iPG;}
