Something is wrong with the file operation.
function fread(),fwrite() read or write binary datas into
a file.But your $hits is a string,that's to say,10 means
character 1 and 0,2 bytes.Therefore when you want to write 10 to file,in fact you write 1 to file because filesize() returns 1 byte.
If...