例子 1
從文件中讀取10 個字節:
<?php
$file = fopen("test.txt","r");
fread($file,"10");
fclose($file);
?>
例子 2
讀取整個文件:
<?php
$file = fopen("test.txt","r");
fread($file,filesize("test.txt"));
fclose($file);
?>
全站熱搜
例子 1
從文件中讀取10 個字節:
<?php
$file = fopen("test.txt","r");
fread($file,"10");
fclose($file);
?>
例子 2
讀取整個文件:
<?php
$file = fopen("test.txt","r");
fread($file,filesize("test.txt"));
fclose($file);
?>
留言列表