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) {
81 fill_file($file_handle, $file_content_type, 1024);
84 rewind($file_handle);
88 rewind($file_handle);
89 $data_from_file = check_read($file_handle, 1030, ( strstr($file_mode, "+") ? 1024 : 1024) );
93 rewind($file_handle);
96 fseek($file_handle, 0, SEEK_END);
98 $data_from_file = check_read($file_handle, 10, 0);
103 fclose($file_handle);