SEO - is it detrimental to dynamically change page contents?

Originally I had the landing page load some Javascript which produced statistics of “Most Popular Pages” and “People Online”, etc. Google Webmaster Tools reported that the page was “slower than 57%”.

To overcome this I created a PHP session counter starting at zero.

If the counter was zero - display hard-coded data and links and images.

else // user decided to view another page then
load the Javascript and display the dynamic statistics of "“Most Popular…”

Will I be penalised for having different content for an identical URL?

Is there any better solution to this problem?


The whole point of dynamic sites is that the contents change continually, so as long as it doesn’t look like you are trying to serve different pages to search engines and real people, you are unlikely to be penalised.