View difference between Paste ID: XnGM3xV7 and NSz5ciB1
SHOW: | | - or go back to the newest paste.
1
<?php
2
$file = 'user.txt';
3
if (empty($_COOKIE['count'])) {
4
    $count = $_COOKIE['count'] + 1;
5-
    $file = 'user.txt';
5+
6
	$current = file_get_contents($file);
7
	$current += 1;
8
	file_put_contents($file, $current);	
9
} 
10
11-
$handle = fopen("user.txt", "r");
11+
12-
echo fgets($handle);
12+
echo file_get_contents($file);
13-
fclose ($handle);
13+