Very simple hits counter

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Very simple hits counter

    create counter.txt file and chmod 777 it.

    and add this php code to your page

    PHP Code:
    <?php
    $file 
    'counter.txt';
    $counter =  intval(file_get_contents($file));
    $counter++;
    file_put_contents($file,$counter);
    echo 
    number_format($counter0','' ').' hits.';
    ?>

    thats all isn't it simple?
    Advertise your mobile site for FREE with AdTwirl


    #2
    Thanks Gumslone

    Comment


      #3
      Its not working

      Originally posted by wapfuture View Post
      Thanks Gumslone
      its not working. I tried it my site went blank

      Comment


        #4
        you wont chmod 777 the page counter.txt i think.

        Comment


          #5
          lol it does work you got to set it up correctly

          make sure to create .txt fileand chmod 777

          Comment

          Working...
          X