# Creates a file and returns the handle. $temp = tmpfile(); fwrite($temp, "Hello, World!"); fclose($temp);