Hey there,
since I wasn't able to solve this problem over at xara-users, I will try my luck here
The page I have a problem with is: www.n90mediatest.magix.net/public
The menu has several Links on it. These are linked to anchors on the page.
In the head code I put this code:
-----------------------------------------
<!-- jQuery enbinden von Google-->
<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">
// jQuery laden
google.load("jquery", "1.3.2");
</script>
<!-- jQuery Code -->
<script type="text/javascript">
$(document).ready(function() {
// Alle internen Links auswählen
$('a[href*=#]').bind("click", function(event) {
// Standard Verhalten unterdrücken
event.preventDefault();
// Linkziel in Variable schreiben
var ziel = $(this).attr("href");
//Scrollen der Seite animieren, body benötigt für Safari
$('html,body').animate({
//Zum Ziel scrollen (Variable)
scrollTop: $(ziel).offset().top
// Dauer der Animation und Callbackfunktion die nach der Animation aufgerufen wird, sie stellt das Standardverhalten wieder her und ergänzt die URL
}, 2000 , function (){location.hash = ziel;});
});
return false;
});
</script>
--------------------------------------
The script worked fine until about 3 weeks ago, since then the automatic scrolling when clicking on one of these links doesn't work anymore.
Do you have any solutions?
Thanks!
-David
Bookmarks