Looks like jquery uses an alternate shortcut on your page.
Instead of the $ shortcut it is defined as jQuery.
Change your script like this and try it again:
function goToByScroll(id){
jQuery('html,body').animate({scrollTop: jQuery("#"+id).offset().top},'slow');
}