
if(document.getElementsByTagName){var $link_element=document.createElement('link');$link_element.setAttribute("rel","stylesheet");$link_element.setAttribute("href","./js/ps6osc.css");$link_element.setAttribute("media","screen");var $head_element=document.getElementsByTagName('head')[0];$head_element.appendChild($link_element);}
function Moo(){var wavecontent='<ul class="wave"><li id="wv1"><a href="#wave1" class="step">1</a></li><li id="wv2"><a href="#wave2" class="step">2</a></li><li id="wv3"><a href="#wave3" class="step">3</a></li><li id="wv4"><a href="#wave4" class="step">4</a></li></ul>';var wavecontroller=document.createElement('div');wavecontroller.setAttribute("id","wavecontroller");var wave1=document.getElementById("wave1");var wave2=document.getElementById("wave2");var wave3=document.getElementById("wave3");var wave4=document.getElementById("wave4");wave1.appendChild(wavecontroller);var wavecontrol=document.getElementById("wavecontroller");wavecontrol.innerHTML=wavecontent;wavecontroller.style.margin="-50px 0 150px 0";var wv1=document.getElementById("wv1");var wv2=document.getElementById("wv2");var wv3=document.getElementById("wv3");var wv4=document.getElementById("wv4");wv1.style.background="yellow";wave2.style.display="none";wave3.style.display="none";wave4.style.display="none";var links=document.getElementsByTagName("a");for(var i=0;i<links.length;i++){if(links[i].className.match("step")){links[i].onclick=function(){var waveId=this.getAttribute("href");var wavy=/#(.*)/;var result=waveId.match(wavy);var wavediv=result[1];wave1.style.display="none";wave2.style.display="none";wave3.style.display="none";wave4.style.display="none";if(wavediv=='wave2'){wave2.appendChild(wavecontroller);wavecontroller.style.margin="-80px 0 150px 0";wave2.style.display="block";wv1.style.background="#fff";wv2.style.background="yellow";wv3.style.background="#fff";wv4.style.background="#fff";}else if
(wavediv=='wave3'){wave3.appendChild(wavecontroller);wavecontroller.style.margin="-180px 0 250px 0";wave3.style.display="block";wv1.style.background="#fff";wv2.style.background="#fff";wv3.style.background="yellow";wv4.style.background="#fff";}else if
(wavediv=='wave4'){wave4.appendChild(wavecontroller);wavecontroller.style.margin="-130px 0 200px 0";wave4.style.display="block";wv1.style.background="#fff";wv2.style.background="#fff";wv3.style.background="#fff";wv4.style.background="yellow";}else{wave1.appendChild(wavecontroller);wavecontroller.style.margin="-50px 0 150px 0";wave1.style.display="block";wv1.style.background="yellow";wv2.style.background="#fff";wv3.style.background="#fff";wv4.style.background="#fff";}
return false;}}}}
function Search(){var searchform=document.forms['search'];var submitform=searchform.ssubmit;submitform.onclick=function(){submitform.value="Wait...";if(searchform.q.value==""){alert('Please enter one or more words to search for');searchform.q.focus();searchform.q.style.border="1px solid red";submitform.value="Try again";return false;}
return true;}}
function Zoom2(){var links=document.getElementsByTagName("a");for(var i=0;i<links.length;i++){if(links[i].className.match("zoom")){links[i].onclick=function(){var imgId=this.getAttribute("href");var divvy=/(.*)\/(.*)/;var result=imgId.match(divvy);var image=result[2];var imgStats=this.getAttribute("rel");var fivvy=/(\d*)#(\d*)/;var imgresult=imgStats.match(fivvy);var imgWidth=imgresult[1];var imgHeight=imgresult[2];var imgAlt=this.getAttribute("alt");var zoomed='<div class="zoom" id="closeform"><img src="http://images.picotech.com/'+image+'" width="'+imgWidth+'" height="'+imgHeight+'" alt="'+imgAlt+'" title="Click to close" /></div>';var imgWidth=parseInt(imgWidth);var booWidth=imgWidth+40;var lefty=(document.body.clientWidth-booWidth)/2;if(lefty<=0){lefty=0;}
var imgHeight=parseInt(imgHeight);var booHeight=imgHeight+20;var topy=(document.body.clientHeight-booHeight)/2;if(topy<=0){topy=0;}
var boo=document.getElementById("zoomed");boo.style.position='absolute';boo.style.left=lefty+'px';boo.style.background='url("http://www.picotech.com/images/closex.png") top right no-repeat #F1F1F1';boo.innerHTML=zoomed;boo.style.display="block";var closeform=document.getElementById("closeform");closeform.onclick=function(){boo.style.display="none";return false;}
return false;}}}}
function createRequestObjectShare(){var request;if(!request){try{request=new XMLHttpRequest();clink=true;}
catch(e){try{request=new ActiveXObject('MSXML2.XMLHTTP');clink=true;}
catch(e){try{request=new ActiveXObject('Microsoft.XMLHTTP');clink=true;}
catch(e)
{clink=false;return false;}}}}
return request;}
var httpshare=createRequestObjectShare();function ShareMe(){if(!document.getElementById('share')){return false;}
var share=document.getElementById('share');share.onclick=function(){var sharex=1;ShareFadeIn();function ShareFadeIn(){var content=document.getElementById('page');try{content.style.opacity=sharex;}catch(e){}
try{content.style.MozOpacity=sharex;}catch(e){}
var opacy=sharex*100;try{content.style.filter='alpha(opacity='+opacy+')';}catch(e){}
try{content.style.KhtmlOpacity=sharex;}catch(e){}
sharex-=0.05;sharex=sharex.toFixed(2);if(sharex>=0.20){setTimeout(ShareFadeIn,10);}else{share.style.display="block";}}
httpshare.open('get','http://www.picotech.com/cgi-bin/share.pl');httpshare.onreadystatechange=HandleShare;httpshare.send(null);return false;}}
function HandleShare(){if(httpshare.readyState==1){var response='<div class="c gap"><img src="http://www.picotech.com/images/loading.gif" width="32" height="32" alt="" /> &#160; Loading...</div>';document.getElementById('shareme').innerHTML=response;var lefty=(screen.availWidth-400)/2;var sharemez=document.getElementById('shareme');sharemez.style.display='block';sharemez.style.position='absolute';sharemez.style.left=lefty+'px';sharemez.style.top='120px';sharemez.style.width='300px';sharemez.style.background='#fff';}
if(httpshare.readyState==4){var response=httpshare.responseText;document.getElementById('shareme').innerHTML=response;var lefty=(screen.availWidth-400)/2;var sharemez=document.getElementById('shareme');sharemez.style.display='block';sharemez.style.position='absolute';sharemez.style.left=lefty+'px';sharemez.style.top='120px';sharemez.style.width='300px';sharemez.style.background='#fff';if(document.getElementById("sharecloseform")){var sharecloseform=document.getElementById("sharecloseform");sharecloseform.onclick=function(){var sharez=0.05;ShareFadeOut();function ShareFadeOut(){var content=document.getElementById('page');try{content.style.opacity=sharez;}catch(e){}
try{content.style.MozOpacity=sharez;}catch(e){}
var opacy=sharez*100;try{content.style.filter='alpha(opacity='+opacy+')';}catch(e){}
try{content.style.KhtmlOpacity=sharez;}catch(e){}
sharez+=0.05;if(sharez<1){setTimeout(ShareFadeOut,10);}}
document.getElementById('shareme').style.display='none';}}
if(document.forms['shareform']){var shareform=document.forms['shareform'];var submitshare=shareform.sharesubmit;submitshare.onclick=function(){submitshare.value="Wait...";}}}}
defaultStatus='Pico Technology PC oscilloscopes and data acquisition products';window.onload=StartUp;function StartUp(){Moo();Zoom2();Search();ShareMe();}
