// ###   R O L L I N G   ###
function rolling (name, image)
  {
     document.images[name].src = image;
  }

// ###   P O P U P   ###
// Chiamata: javascript:popUp('formUpload.php?localDir=$table&table=$table','upload',300,400,1,0,0,0)
function popUp (page, name, width, height, scrollbars, resizable, menubar, status)
  {
     //window.open (page, name, width = ' + width + ', height = ' + height + ', 'status = ' + status + ', menubar = ' + menubar + ', scrollbars = ' + scrollbars + ', resizable = ' + resizable);
     window.open (page, name, 'width=' + width + ', height=' + height + 'status = ' + status + ', menubar = ' + menubar + ', scrollbars = ' + scrollbars + ', resizable = ' + resizable);
  }
  
  //### NUMBER CHECK ###
function keyCheck(eventObj, obj)
{
        var keyCode

        // Check For Browser Type
        if (document.all){
                keyCode=eventObj.keyCode
        }
        else{
                keyCode=eventObj.which
        }

        var str=obj.value

        if(keyCode==44){
                if (str.indexOf(",")>0){
                        return false
                }
        }
        if(keyCode==8){
                if (str.indexOf("")>0){
                        return false
                }

        }

        if((keyCode<48 || keyCode >58)   &&   (keyCode != 44)  &&   (keyCode != 8)){ // Allow only integers and decimal points
                return false
        }

        return true
}
