simple page counter & html


#1

I have a simple php counter and a html page calling to include the counter dat file info, my problem is how do i activate the counter.php to incrument the counter.dat file so i can read the updated counter.dat file ?
thanks


#2

You will need to look into using fread(), and fwrite(). For more help on using them try here http://www.php.net/fread


#3

The counter works fine if i run the counter.php, what i need is a way to run it from the html and get the results back into the html


#4

I am not so sure I understand your problem or what you are asking for, but if you are asking how to include that counter script into your html document then use the following code:

[php]<?
include(‘the/path/counter.php’);
?>[/php]