﻿var wind=null;function ShowProductPopup(URL,contentId,furl)
{var nUrl;if(furl!=null&&furl!="")
{nUrl=URL+'?f='+furl;}
else if(contentId!=null&&contentId!="")
{nUrl=URL+'?id='+contentId;}
pop_up(nUrl,"Show Product",760,700);return false;}
function pop_up(URL,PopUpName,Width,Height)
{try
{if(Width==""||Width==null)Width=486;if(Height==""||Height==null)Height=500;var features=',directories=0,location=0,menubar=0,scrollbars=1,status=0,toolbar=0,resizable=1,width='+Width+',height='+Height+',screenX=15,screenY=15,top=15,left=15';URL=URL.replace(/\s/,'%20');wind=window.open(URL,"",features);wind.focus();}
catch(err){}}
function getElement(eID)
{var ret=null;if(document.layers)
{try
{ret=document.layers(eID);}
catch(e){}}
else if(document.getElementById)
{try
{ret=document.getElementById(eID);}
catch(e){}}
else if(document.all)
{try
{ret=document.all(eID);}
catch(e){}}
return ret;};function AddFavourite(title,url)
{if(window.sidebar)
{window.sidebar.addPanel(unescape(title),unescape(url),'');}
else if(window.opera&&window.print)
{var mbm=document.createElement('a');mbm.setAttribute('rel','sidebar');mbm.setAttribute('href',unescape(url));mbm.setAttribute('title',unescape(title));mbm.click();}
else if(window.external)
{window.external.AddFavorite(unescape(url),unescape(title));}
else
{alert("Sorry adding a bookmark is not supported on this browser. You will have to add the bookmark/favourite manually.");}};function textBoxKeyPress(e,ActionControlId)
{try
{var ie=(document.all)?true:false;var nn=(document.layers)?true:false;var icode,ncode,key;if(ie)
{icode=event.keyCode;ncode=0;key=String.fromCharCode(event.keyCode);}
else if(nn)
{icode=0;ncode=e.which;key=String.fromCharCode(e.which);}
if(icode==13||ncode==13)
{var aControl=getFormElement(ActionControlId);if(aControl!=null)
{aControl.click();return false;}}}
catch(err){}
return true;};