AIM = { frame : function(c) { var n = 'f' + Math.floor(Math.random() * 99999); var d = document.createElement('DIV'); d.innerHTML = ''; document.body.appendChild(d); var i = document.getElementById(n); if (c && typeof(c.onComplete) == 'function') { i.onComplete = c.onComplete; } return n; }, form : function(f, name) { f.setAttribute('target', name); }, submit : function(f, c) { AIM.form(f, AIM.frame(c)); if (c && typeof(c.onStart) == 'function') { return c.onStart(); } else { return true; } }, loaded : function(id) { var i = document.getElementById(id); if (i.contentDocument) { var d = i.contentDocument; } else if (i.contentWindow) { var d = i.contentWindow.document; } else { var d = window.frames[id].document; } if (d.location.href == "about:blank") { return; } if (typeof(i.onComplete) == 'function') { i.onComplete(d.body.innerHTML,i); } } } function startCallback() { return true; } function completeCallback(response,frame) { $('c_form').innerHTML = response; if(String(response).substr(1,3) == 'div' && typeof(pageTracker) == 'object') { pageTracker._trackPageview("/contact_response"); window.setTimeout("hide_contactform()",5000); } document.body.removeChild(frame.parentNode); } function checkform() { return true; if ($('ff_name').value != '' && $('ff_email').value != '' && $('ff_message').value != '') return true; alert('Bitte füllen Sie alle Felder aus;'); return false; } function cbr() { var cbr_no = $('cbr_no').value; if(cbr_no == 'Ihre Telefonnummer' || cbr_no == '') { alert('Bitte geben Sie Ihre Telefonnummer ein.'); return false; } $('cbr_rsl').innerHTML = "..."; new Ajax.Updater('cbr_rsl','http://www.sebaldsolutions.de/cbr.ajax.php',{method:'post',parameters: {cbr_no: cbr_no}, evalScripts: true }); if(typeof(pageTracker) == 'object') { pageTracker._trackPageview("/callback"); } } function show_contactform() { if(typeof(dia_show)=='object') { dia_show.stop(); } if($('c_dia_show').style.visibility = "visible") new Effect.Fade('c_dia_show',{duration:0.5,queue:'end'}); if($('c_map').style.visibility = "visible") new Effect.Fade('c_map',{duration:0.5,queue:'end'}); new Effect.Appear('c_form',{duration:0.5,queue:'end'}); if(typeof(pageTracker) == 'object') { pageTracker._trackPageview("/contact"); } } function hide_contactform() { new Effect.Fade('c_form',{duration:0.5,queue:'end'}); new Effect.Appear('c_dia_show',{duration:0.5,queue:'end'}); if(typeof(dia_show)=='object') { //window.setTimeout("dia_show.start()",5000); } } function show_map() { if(typeof(dia_show)=='object') { dia_show.stop(); } if($('c_dia_show').style.visibility = "visible") new Effect.Fade('c_dia_show',{duration:0.5,queue:'end'}); if($('c_map').style.visibility = "visible") new Effect.Fade('c_form',{duration:0.5,queue:'end'}); $('c_map').show(); loadmap(); if(typeof(pageTracker) == 'object') { pageTracker._trackPageview("/map"); } } function hide_map() { new Effect.Fade('c_map',{duration:0.5,queue:'end'}); new Effect.Appear('c_dia_show',{duration:0.5,queue:'end'}); if(typeof(dia_show)=='object') { //window.setTimeout("dia_show.start()",5000); } }