Home  >  Article  >  Backend Development  >  PHP引入文件出现空白行有关问题

PHP引入文件出现空白行有关问题

WBOY
WBOYOriginal
2016-06-13 13:16:051244browse

PHP引入文件出现空白行问题
文件末尾的 PHP 代码段结束标记可以不要,有些情况下当使用 include() 或者 require()时省略掉会更好些,这样不期望的白空格就不会出现在文件末尾,之后仍然可以输出响应标头。在使用输出缓冲时也很便利,就不会看到由包含文件生成的不期望的白空格。

1楼xming432124分钟前
其实了 你可以不写代买结尾的?> 就没有空白了
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