| www.freegive.co.uk - Don't Throw Unwanted Items Away, Give it Away on Freegive |
| Hit Counter | Total Visits: 1545 Free Stuff Directory Free contact forms with file upload |
|
Free Hit Counter PHP  »
Add a free hit counter to your web pages
Track the number of uniques or individual visits to your web pages. No email, registration or personal information is required.
Looking for a quick and simple (AND 100% FREE!!) way to keep track of your web page visitors? Well you found it. Get free contact forms with file upload | Download Free Hit Counter Here Free Hit Counter PHP Code: 1. Create a counter text file of the name hitcounter.txt and save it to the same directory you will put your hit counter in. 2. Open your php editor. Save the document as counter.php. Set your opening statement for PHP script.
3. Set the variable for the file named hitcounter.txt and place this between your PHP tags. remember to place the filename in quotes. place the semicolon on the end of the line to end the command.
4. Set the number of visits to the current value of the contents of the hitcounter.txt file:
5. When the script is accessed as the page loads, it not only reads the current number of hits on the page in the hitcounter.txt, it must increase the value by 1 for the current hit to be recorded. Add 1 to your value of $hits and call it $hits.
6.Open the file that is keeping count so we can write to it
7. Replace the value in the file with the new $hits number after it was incremented.
8. You must close the file next.
9. Set the code to display your hit number.
10. Save your php file in same directory as the text file. 11. To use this script you just have to add a php statement that calls that php file. Use the following include:
Hit Counter Demo: Total Views: 1546  » Download Free Hit Counter Here Free contact form with file upload support and captcha from freegive.co.uk Please help spread the word by linking to Freegive at ( http://www.freegive.co.uk ) from your website or go to "Add Freegive To Your Site" page. Thanks for your interest in Freegive. |
| © Freegive | About us | Privacy and safety | Advertise with us | Contact us | More Freegive | How to avoid scams and fraud Site Map |