Jump to content

Archived

This topic is now archived and is closed to further replies.

digi duck

counting clicks on submit button

Recommended Posts

--------------------------------------------------------------------------------

Hi i was wondering if any1 knew of a way how to count clicks of a submit button and show thi number on a different page without using a database.
This is my site http://gamesigs.co.uk and what i would like is for evertime someone clicks on the submit button on gamesigs.co.uk/create.php for it to add one on to the count and show this count on the index.php page. Any ideas would be appreciated. Also i don't think i can put any more code in the _sig_create.php (the file the button geos to) as it messes up the page.
Thanks a lot Digi.

Share this post


Link to post
Share on other sites
use a text file to store the count and have the counter on the page/code the button takes you to.

Share this post


Link to post
Share on other sites
use the fopen command to open, something like this:
[code]
<?php
$handle = fopen("yourfile.txt", "w");
?>
[/code]

then youll need to use the fwrite command cant remember how to use this so read up on it at [url=http://uk2.php.net/manual/en/function.fwrite.php]http://uk2.php.net/manual/en/function.fwrite.php[/url]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.