function startComponents() {
    // Suche
    $('button_suche').onmouseover = function() {
        $('button_suche').addClassName('button_suche_h');
    }
    $('button_suche').onmouseout = function() {
        Element.removeClassName('button_suche', 'button_suche_h');
    }

    // Box 1
    if ($('box_1').className != 'box_1_h') {
        $('box_1').onmouseover = function() {
            $('box_1').className = 'box_1_h';
        }
        $('box_1').onmouseout = function() {
            $('box_1').className = 'box_1_l';
        }
    }

    // Box 2
    if ($('box_2').className != 'box_2_h') {
        $('box_2').onmouseover = function() {
            $('box_2').className = 'box_2_h';
        }
        $('box_2').onmouseout = function() {
            $('box_2').className = 'box_2_l';
        }
    }

    // Box 3
    if ($('box_3').className != 'box_3_h') {
        $('box_3').onmouseover = function() {
            $('box_3').className = 'box_3_h';
        }
        $('box_3').onmouseout = function() {
            $('box_3').className = 'box_3_l';
        }
    }

    // Box 4
    if ($('box_4').className != 'box_4_h') {
        $('box_4').onmouseover = function() {
            $('box_4').className = 'box_4_h';
        }
        $('box_4').onmouseout = function() {
            $('box_4').className = 'box_4_l';
        }
    }

    // BottomBox 1
    if ($('bbox_box1').className != 'bbox_box1_h') {
        $('bbox_box1').onmouseover = function() {
            $('bbox_box1').className = 'bbox_box1_h';
        }
        $('bbox_box1').onmouseout = function() {
            $('bbox_box1').className = 'bbox_box1_l';
        }
    }

    // BottomBox 2
    if ($('bbox_box2').className != 'bbox_box2_h') {
        $('bbox_box2').onmouseover = function() {
            $('bbox_box2').className = 'bbox_box2_h';
        }
        $('bbox_box2').onmouseout = function() {
            $('bbox_box2').className = 'bbox_box2_l';
        }
    }

    // BottomBox 3
    if ($('bbox_box3').className != 'bbox_box3_h') {
        $('bbox_box3').onmouseover = function() {
            $('bbox_box3').className = 'bbox_box3_h';
        }
        $('bbox_box3').onmouseout = function() {
            $('bbox_box3').className = 'bbox_box3_l';
        }
    }

    // BottomBox 4
    if ($('bbox_box4').className != 'bbox_box4_h') {
        $('bbox_box4').onmouseover = function() {
            $('bbox_box4').className = 'bbox_box4_h';
        }
        $('bbox_box4').onmouseout = function() {
            $('bbox_box4').className = 'bbox_box4_l';
        }
    }
}

function ajaxRequest(url,params,targetFunc,method) {
    url = '/services/'+url+'.htx';
    if(!method) method='get';
	helpAjax = new Ajax.Request(url,
		{
  		method: method,
  		parameters: params,
    	onComplete: eval(targetFunc)
  	}
  );
}

function fade(objid,tduration) {
    if(!tduration) tduration = 0.2;
    new Effect.Fade(objid,{ duration: tduration, from: 1.0, to: 0.0  });
}

function appear(objid,tduration) {
    if(!tduration) tduration = 0.2;
    new Effect.Appear(objid,{ duration: tduration, from: 0.0, to: 1.0  });
}


function checkMail(email) {
 var a = false;
 var res = false;

 if(typeof(RegExp) == 'function') {
    var b = new RegExp('abc');
    if(b.test('abc') == true){
        a = true;
    }
 }

 if(a == true) {
  reg = new RegExp('^([a-zA-Z0-9\\-\\.\\_]+)'+
                   '(\\@)([a-zA-Z0-9\\-\\.]+)'+
                   '(\\.)([a-zA-Z]{2,4})$');
  res = (reg.test(email));
 }
 else {
  res = (email.search('@') >= 1 &&
         email.lastIndexOf('.') > email.search('@') &&
         email.lastIndexOf('.') >= email.length-5)
 }
 return(res);
}