The problem has to do with the way the script current handles errors. To fix the problem:
Open counter.php and find:
PHP Code:
include($OPTION['Absolute_Path']."counter-error.php");
And REPLACE it with:
PHP Code:
include_once($OPTION['Absolute_Path']."counter-error.php");
The file was being included multiple times on multiple errors as the script was not being killed and therefore the function was being declared multiple times.
Also, the easiest way to get rid of the notice errors is to properly set error reporting levels (as your default levels for all of PHP are too high). You can set them in the script by adding the following to the top of counter.php file (on the line below <?php ):
PHP Code:
error_reporting(E_ALL ^ E_NOTICE);
The script is old but it still works well (and is easy) which is I guess why so many still use it. When I have time I plan to release a new version of it that is structurally better and completely rewrites the script itself (version 4.0).