There are many php
hit counter tutorials out there.
Heres one I found doing a google search:
https://code.google.com/p/simphp/
All you would have to do is call:
<? include("home/public_html/hits/simphp.php"); ?>
Then place this in the div you want counted:
<div id="count"><? echo $info; ?></div>
To detect if a div is visible in the browser window, use jQuery
: