Javascript: ScrollIntoView()

After a last minute request to change a website so it automatically scrolls down to show Google Map when a search is submitted I was preparing to write some tacked on jQuery to provide the functionality. That was until I came across a Javascript function which already did exactly what I wanted, ScrollIntoView().

var el = document.getElementById('map_container');

Leave a Reply

Your email address will not be published. Required fields are marked *