Lines Matching refs:file

2 Test fgetss() function : usage variations - read/write modes, file pointer at EOF 
13 Description: Gets line from file pointer and strip HTML tags
39 /* try reading the file opened in different modes of reading */
43 echo "\n-- Testing fgetss() with file opened using $file_modes[$mode_counter] mode --\n";
45 /* create an empty file and write the strings with tags */
47 fwrite($file_handle,$string_with_tags); //writing data to the file
49 echo "Error: failed to open file $filename!\n";
52 // rewind the file pointer to beginning of the file
58 echo "-- Reading when file pointer points to EOF --\n";
59 var_dump( fseek($file_handle,0,SEEK_END) ); // now file pointer at end
60 var_dump( ftell($file_handle) ); //ensure file pointer at end
62 var_dump( ftell($file_handle) ); // find out file position
63 var_dump( feof($file_handle) ); // ensure that file pointer is at eof
65 // now file is at the end try reading with length and allowable tags,expecting false
67 var_dump( ftell($file_handle) ); // find out file position
68 var_dump( feof($file_handle) ); // ensure that file pointer is at eof
71 // close the file
74 // delete the file
83 -- Testing fgetss() with file opened using w+ mode --
88 -- Reading when file pointer points to EOF --
98 -- Testing fgetss() with file opened using w+b mode --
103 -- Reading when file pointer points to EOF --
113 -- Testing fgetss() with file opened using w+t mode --
118 -- Reading when file pointer points to EOF --
128 -- Testing fgetss() with file opened using a+ mode --
133 -- Reading when file pointer points to EOF --
143 -- Testing fgetss() with file opened using a+b mode --
148 -- Reading when file pointer points to EOF --
158 -- Testing fgetss() with file opened using a+t mode --
163 -- Reading when file pointer points to EOF --
173 -- Testing fgetss() with file opened using x+ mode --
178 -- Reading when file pointer points to EOF --
188 -- Testing fgetss() with file opened using x+b mode --
193 -- Reading when file pointer points to EOF --
203 -- Testing fgetss() with file opened using x+t mode --
208 -- Reading when file pointer points to EOF --