Home >Backend Development >PHP Tutorial >读取文件少了一半数据

读取文件少了一半数据

WBOY
WBOYOriginal
2016-06-23 14:38:10885browse

读取文件少了一半数据

<?php		$fp=fopen('d:\www\dx\test\test.php','r');	while(!feof($fp)){		$line=fgets($fp, 4096);		echo $line;	}	fclose($fp);?>


回复讨论(解决方案)

开头部分数据不见了

其实不是不见了,你右击查看源代码,所有的数据都在里面。不过应该是在 之间的代码全部隐藏,具体原因,不太清楚...

被  包裹的内容都被浏览器视为标记,自然不会在浏览器中显示

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn