
//打开文件
$fp=fopen(tmp.html, r);
//读取文件内容 可以用以下两个函数进行操作 fread,file_get_contents
$str=fread($fp, filesize(tmp.html)); //filesize为获取文件大小
$content=file_get_contents(tmp.html);
//写文件
$news=fopen(news.html, w);
fwrite($news, $content);
//关闭文件流
fclose($fp);
fclose($news);
echo $content;
?
© 版权声明
文章版权归作者所有,未经允许请勿转载。
相关文章
暂无评论...