+ Reply to Thread
Results 1 to 5 of 5

Thread: Another php counter prob -.-

  1. #1
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    Another php counter prob -.-

    I give you 30 credits if you find out why the count aren't showed

    PHP Code:
    <?php 

    if(file_exists("count.dat")) 

        
    $fp fopen("count.dat""r"); 
        
    $count fgets($fp1024); 
        
    $count++; 
        
    fclose($fp);     
        echo 
    "<strong><font color=red face=arial size=3>$count</font></strong> has played this game "
        
    $fp fopen("count.dat""w"); 
        
    fwrite($fp$count); 
        
    fclose($fp); 


    else 

        echo 
    "<strong><font color=red face=arial size=3>CREAE count.dat FILE, Change the file permission  for count.dat file to                         646(RW-,R--,RW-).</font></strong>" ;
    }

    ?>
    It just show "has played this game"

  2. #2
    satheesh's Avatar
    satheesh is offline x10 Elder satheesh is an unknown quantity at this point
    Join Date
    Sep 2007
    Location
    Tamil Nadu,India
    Posts
    883

    Re: Another php counter prob -.-

    It correctly worked on my computer.
    Change the permission of the "count.dat" file.
    I want to buy Some Scripts So Please Click This link:http://affiliate.tufat.com/index.php?id=4384
    Please rate my site:Click here




  3. #3
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    Re: Another php counter prob -.-

    Sry but I've already fixed it. But I need another counter. I will give you 100 credits if you make it. In the file counterg.php will the counter be. In every page I should include it using the php INCLUDE statement. I need the counter to give the pages IDs so it doesen't show the same count on every page.

  4. #4
    satheesh's Avatar
    satheesh is offline x10 Elder satheesh is an unknown quantity at this point
    Join Date
    Sep 2007
    Location
    Tamil Nadu,India
    Posts
    883

    Re: Another php counter prob -.-

    Sorry,I don't understand your message.
    Please explain more.
    I want to buy Some Scripts So Please Click This link:http://affiliate.tufat.com/index.php?id=4384
    Please rate my site:Click here




  5. #5
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    Re: Another php counter prob -.-

    Go to my page at http://jagf.pcriot.com/flash. It is a flash gaming site. Every game should have a hit counter that will record how much the game has been played. like game 1 has been played 2 times and game 2 has been played 1 time. All the counter scripts I have found show 3 here. I want it to show only the hits for that page.

+ Reply to Thread

Similar Threads

  1. tons of PHP Resources
    By Chris S in forum Scripts & 3rd Party Apps
    Replies: 10
    Last Post: 01-16-2009, 10:07 AM
  2. Unstand PHP?
    By o0slowpaul0o in forum Tutorials
    Replies: 8
    Last Post: 01-07-2008, 09:16 PM
  3. Sigo con problemas con phpbb2
    By reciecho in forum Soporte
    Replies: 7
    Last Post: 10-20-2007, 06:28 PM
  4. "PHP Startup: Invalid Library" - Interesting error
    By javaguy78 in forum Free Hosting
    Replies: 5
    Last Post: 03-27-2007, 02:33 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers