September 2001
Intermediate to advanced
768 pages
32h 45m
English
string fgetc(resource file_handle) Reads a character from a file.
Returns:
Single character or FALSE
Description:
Returns a single character from a file. If the location of the file pointer is at EOF (end of file), FALSE is returned.
Note:
fgetc() is quite inefficient and should not be used to read large amounts of data. If you need to process text from a file one character at a time, use fgets() to read in the data one line at a time and then process the line one character at a time with a looping construct such as while or for.
Warning:
Because some of the filesystem functions to read/write from files partially share the same code, one or more of the bugs reported elsewhere may also apply to this function.
3.0.6: Function not binary-safe. ...
Read now
Unlock full access