Title: Replacing existing counter in .tpl file plus start value. Post by: Danwest on February 12, 2012, 05:25:36 AM Hello,
pq Visitor Counter and Tracker looks like an excellent script, thank you making it available. My website consists of php pages that include tpl pages (no htm pages) and I already am using a counter that I am looking at replacing with pqVisitor. My current counter is in a file called wrapper.tpl Code: include('/mycompletepath/counter/counter.php'); Code: <?php include("/mycompletepath/pqcounter/counter.php"); ?> My counter since it started is at over 60,000 total visitors, is there a start value that can be set during the install or would I have to manually edit the start value in the database after it is installed? Another quick question, regarding the configuration of counter.php. For the line Code: $duration = 4*7*24*60*60; // seconds before IP Address is counted as a new visitor again I don't want them to be counted as a new visitor until either the next day or a 24 hour period, do I just remove everything other than 24 so it looks like this? Code: $duration = 24; // seconds before IP Address is counted as a new visitor again Thank You Dan Title: Re: Replacing existing counter in .tpl file plus start value. Post by: pftq on February 12, 2012, 01:29:19 PM Hi, you'd have to just manually edit the value in your MySQL database (not really hard, just open the table up in PHPAdmin or similar and edit the value).
The include doesn't have to be at the top of the file. For the 24-hr period, notice the setting is in seconds. So you'd have to do 24*60*60 (#hrs * min * sec). |