Page 1 of 1

How to display All & Daily clicks?

Posted: Mon May 27, 2013 2:10 pm
by danten1
Hi!
I have a link and I want to display All clicks and Daily clicks clicked on it. How all changes and scripts should look like? Any ideas? Sorry for my English.

Re: How to display All & Daily clicks?

Posted: Mon May 27, 2013 7:30 pm
by Henrie
To find how to display 'All clicks', open the file readme.htm which is inside the downloaded zip file of ccount. It is explained there. Here is a copy/paste of that chapter
>> Displaying number of clicks on a link

CCount from version 1.1 on allows you to display the number of clicks on a link at your website. To display number of clicks on your web page follow these two steps:

1. Add this code in your HTML document HEAD (paste it somewhere between <head> and </head> HTML tags):

<script language="Javascript" src="http://www.domain.com/ccount/display.php">
<!--
//-->
</script>

CHANGE http://www.domain.com/ccount/display.php to the URL of display.php on your server!

2. Add this code where you want the number of clicks to appear:

<script language="Javascript">ccount_display('LINK_ID')</script>

REPLACE LINK_ID with the ID number of the link you want to display the count for (IDs can be found when you login to CCount admin panel)! To display number of clicks on the link with ID 13 you would use this code:

<script language="Javascript">ccount_display('13')</script>

You may add any HTML tags around this code to format the count number. This code for example:

Link 9 has been clicked <font color="#FF0000"><script language="Javascript">ccount_display('9')</script></font> times

would produce such output:

Link 9 has been clicked 478 times

If you get an undefined error instead of a number please double-check the ID number you entered in the code above
To display "Daily clicks" is not possible with the script as it is now. One could try to edit the script. But I think you will have to do it yourself (or find someone to do it for you) because that kind of help is beyond the support given in this forum by Klemen.

Greetings,
Henrie