Thread: PHP counter
View Single Post
  #1 (permalink)  
Old 04-21-2008, 12:53 PM
fimmy fimmy is offline
Newbie
 
Join Date: Apr 2008
Posts: 3
Credits: 0
Rep Power: 0
fimmy is on a distinguished road
Default PHP counter

Pls could some1 tell me what wrong with this code

Thanks
PHP Code:
    <?php
    
      
echo '<div id="date">' date("d/m/Y") . '</div>';
$filename"counterlog2.txt" ;
$fd fopen ($filename "r") or die ("Can't open $filename") ;
$fstring fread ($fd filesize ($filename)) ;
echo 
'<div id="counter">Visits: ' "$fstring" '</div>';
fclose($fd) ;

$fd fopen ($filename "w") or die ("Can't open $filename") ;
$fcounted $fstring ;
$foutfwrite ($fd $fcounted ) ;
fclose($fd) ;
  
?>

Last edited by John; 04-21-2008 at 01:32 PM.
Reply With Quote

Sponsored Links