Lines Matching refs:file
7 Description: Gets a line from file pointer
10 // include the file.inc for common test funcitons
11 include ("file.inc");
19 echo "\n-- Testing fgets() with file opened using mode $file_mode --\n";
23 …irname(__FILE__), 1, $file_content_type, 0755, 50, "w", "fgets_basic", 1, "bytes"); //create a file
24 …$filename = dirname(__FILE__)."/fgets_basic1.tmp"; // this is name of the file created by create_f…
27 echo "Error: failed to open file $filename!";
31 echo "-- fgets() with default length, file pointer at 0 --\n";
33 var_dump( ftell($file_handle) ); // ensure the file pointer position
36 echo "-- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --\n";
39 var_dump( ftell($file_handle) ); // ensure the file pointer position
42 //close file
45 // delete file
55 -- Testing fgets() with file opened using mode r --
57 -- fgets() with default length, file pointer at 0 --
61 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
67 -- fgets() with default length, file pointer at 0 --
71 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
77 -- fgets() with default length, file pointer at 0 --
82 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
89 -- fgets() with default length, file pointer at 0 --
93 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
99 -- Testing fgets() with file opened using mode rb --
101 -- fgets() with default length, file pointer at 0 --
105 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
111 -- fgets() with default length, file pointer at 0 --
115 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
121 -- fgets() with default length, file pointer at 0 --
126 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
133 -- fgets() with default length, file pointer at 0 --
137 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
143 -- Testing fgets() with file opened using mode rt --
145 -- fgets() with default length, file pointer at 0 --
149 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
155 -- fgets() with default length, file pointer at 0 --
159 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
165 -- fgets() with default length, file pointer at 0 --
170 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
177 -- fgets() with default length, file pointer at 0 --
181 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
187 -- Testing fgets() with file opened using mode r+ --
189 -- fgets() with default length, file pointer at 0 --
193 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
199 -- fgets() with default length, file pointer at 0 --
203 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
209 -- fgets() with default length, file pointer at 0 --
214 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
221 -- fgets() with default length, file pointer at 0 --
225 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
231 -- Testing fgets() with file opened using mode r+b --
233 -- fgets() with default length, file pointer at 0 --
237 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
243 -- fgets() with default length, file pointer at 0 --
247 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
253 -- fgets() with default length, file pointer at 0 --
258 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
265 -- fgets() with default length, file pointer at 0 --
269 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
275 -- Testing fgets() with file opened using mode r+t --
277 -- fgets() with default length, file pointer at 0 --
281 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
287 -- fgets() with default length, file pointer at 0 --
291 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
297 -- fgets() with default length, file pointer at 0 --
302 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --
309 -- fgets() with default length, file pointer at 0 --
313 -- fgets() with length = 23, Expected: 22 chars, file pointer at 0 --