Fix Upcoming Events List Causing Webpage To Scroll Down

Internet Explorer version 7 has several bugs that cause the webpage containing Upcoming Events List javascript code to scroll down to the top of the Upcoming Events List if the Upcoming Events List is below the browser window when the page opens.  There are two methods to fix this problem:

Method 1

To fix the problem, change the DOCTYPE  declaration at the top of the webpage to be:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

DOCTYPES known to cause the problem are:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Method 2

Insert the following code at the very bottom of your web page:

<!--[if IE 7]>
<script type="text/javascript">
self.scrollTo(0, 0);
</script>
<![ENDIF]-->

This will reset the scroll of the page to the top. This will only affect Internet Explorer version 7. All other browsers and versions will ignore this as an HTML comment.

 



Article ID: 73
Last updated: 04 Nov, 2013
Revision: 1
Website Integration -> Fix Upcoming Events List Causing Webpage To Scroll Down
https://www.calendarwiz.com/knowledgebase/entry/73/