//NO HOVER // remove hover from links containing images
function setClassNames()
{
var numImgs = document.images.length;
for(var i=0;i<numImgs;i++)
{
var img = document.images[i];
if(img.parentNode.nodeName == "A")
img.parentNode.className += " nohover";
};
}
// SMARTLINK // code generated by David Power's 'smartlink' extension
// replaces 'target="_blank"' to open links in new browser window
function dpSmartLink(u,n,w,h,p) { // v1.4 by David Powers
  var a,j,k,x,y,f='';if(!n){n='';}if(w){f+='width='+w+',';}if(h){f+='height='+h+',';}
  if(p){p=p.split(':');if(p[0]!='z'){p[0]=='c'?(x=(screen.width-w)/2):x=p[0];f+='left='+x+',';}
  if(p[1]!='z'){if(p[0]=='c'){y=(screen.height-h-p[1])/2;if(navigator.appName.indexOf('Op')!=-1){
  y-=96;y=y<0?0:y;}}else{y=p[1];}f+='top='+y+',';}}a=arguments.length;if(a>5){for (k=5;k<a;k++){
  switch(arguments[k]){case 'all':f+='toolbar,menubar,location,scrollbars,status,resizable,';break;
  case 't':f+='toolbar,';break; case 'm':f+='menubar,';break;case 'l':f+='location,';break;
  case 'sc':f+='scrollbars,';break;case 's':f+='status,';break;case 'r':f+='resizable,';}}}
  if(f.charAt(f.length-1)==','){f=f.slice(0,-1);}j=window.open(u,n,f);j.focus();
  document.MM_returnValue=false;
}
// CHECK VALUE // script to return default value to empty input 
// give your input any default value, and call with onblur="checkValue(this)"
function checkValue(inputName){
if (inputName.value == ''){
inputName.value = inputName.defaultValue;
};
}
// extract numeric - allow numeric input only
// invoke like this:  onkeyup="this.value=extractNumeric(this.value)"
function isNumericKey(e) {
   var k = document.all ? e.keyCode : e.which;
   return ((k > 47 && k < 58) || k == 8);
}
function extractNumeric(str) {
   return str.replace(/\D/g,"");
}
// extract currency - allow numbers and one decimal point only
// invoke like this: onKeyUp="extract_currency(this)"
function extract_currency(obj){
  if (!/^\d+(\.\d*)?$/.test(obj.value)){
    obj.value= theVal = obj.value.replace(/[^0-9.]/g,'');
    if(theVal>""){
      obj.value=parseFloat("0"+theVal);
      obj.focus()
    }
  }
}
// extract signed - allow numbers , one period and leading hyphen only
// invoke like this: onKeyUp="this.value=extractSigned(this.value)"
function extractSigned(str)
 {
   str += '';
   var rgx = /^\d|\.|-$/;
   var out = '';
   for( var i = 0; i < str.length; i++ )
   {
     if( rgx.test( str.charAt(i) ) ){
       if( !( ( str.charAt(i) == '.' && out.indexOf( '.' ) != -1 ) ||
              ( str.charAt(i) == '-' && out.length != 0 ) ) ){
         out += str.charAt(i);
       }
     }
   }
   return out;
 }