Lines Matching refs:file_handle
22 /* Function : function check_read(resource $file_handle, int $read_size, int $expect_size)
25 $file_handle : File Handle
30 function check_read($file_handle, $read_size, $expect_size) {
32 var_dump( ftell($file_handle) );
33 var_dump( feof($file_handle) );
37 $data_from_file = fread($file_handle, $read_size);
46 var_dump( ftell($file_handle) );
48 var_dump( feof($file_handle) );
73 $file_handle = fopen($filename, $file_mode);
74 if (!$file_handle) {
80 fill_file($file_handle, $file_content_type, 1024);
83 rewind($file_handle);
86 rewind($file_handle);
87 $data_from_file = check_read($file_handle, 1030, ( strstr($file_mode, "+") ? 1024 : 0) );
92 rewind($file_handle);
94 fseek($file_handle, 0, SEEK_END);
96 $data_from_file = check_read($file_handle, 10, 0);
101 fclose($file_handle);