This is an old revision of the document!
WMPRO, WMMINI FW >= 1.0 WMMEGA FW >= 2.0
Close a file, stream or socket
handle: Valid handle of a previously opened resource
None
<? $f=fopen("/test.txt","r"); // open the file for reading and get the file handle if ($f) { print(fgets($f)); // print the first line of the file fclose($f); // close the file referenced by file handle } else { print("Unable to open file /test.txt"); } ?>
fopen() - Open a file for reading or writing
f485open() - Open the RS-485 port at the specified baud rate and parity
fseropen() - Open the serial port at the specified baud rate with optional parameters
fsockopen() - Open an internet socket connection with optional timeout
fread() - Return bytes from a file or stream
fgets() - Return a single line from a file or stream, with optional size limit
fwrite() - Write data to a file or stream