$( document ).ready(function() { $( ".jQinsertLeaflet" ).attr('title','Save on leaflet'); $( ".jQinsertLeaflet" ).click(function( event ) { var accID=$('input:hidden[name=INFOaccID]').val(); $.ajax({ type: "POST", url: "/ajax.php", data: { insertLeaflet: accID} }).done(function( msg ) { writeMessage('#d-nav',msg); checkLeaflet(); }); }); if($('#messageok, #messagefailed, .hinweisGREEN').show()){ deleteMessage('#messageok, #messagefailed, .hinweisGREEN'); } $( ".openNewW" ).click(function(event) { window.open(this.href);return false; }); $("#logItemTopR" ).click(function(event) { logOpenClose(); }); $("#languageContainer").click(function(event) { langOpenClose(); }); checkLeaflet(); $('a[href*=#]').bind("click", function(event) { // duration in ms var duration=500; // easing values: swing | linear var easing='swing'; // get / set parameters var newHash=this.hash; var target=$(this.hash).offset().top; var oldLocation=window.location.href.replace(window.location.hash, ''); var newLocation=this; // make sure it's the same location if(oldLocation+newHash==newLocation) { // animate to target and set the hash to the window.location after the animation $('html:not(:animated),body:not(:animated)').animate({ scrollTop: target }, duration, easing, function() { // add new hash to the browser location window.location.href=newLocation; }); // cancel default click action return false; } }); showAccGallery(); $('body').append( '
'); }); function logOpenClose(){ if($("#logItemTopR div").is(":visible")){ $('#logItemTopR div').hide(); $('#logItemTopR').removeClass('backgroundIMGArrowBottom'); }else{ $('#langContent').hide(); $('#logItemTopR').addClass('backgroundIMGArrowBottom'); $('#logItemTopR div').show(); } } function langOpenClose(){ if($("#langContent").is(":visible")){ $('#langContent').slideUp('fast'); }else{ $('#logItemTopR div').hide(); $('#langContent').slideDown('fast'); } } function checkLeaflet(){ var img=''); //alert(msg); }); } function writeMessage(Container,message){ $('