Home > Backend Development > PHP Tutorial > The closing PHP snippet tag at the end of the file is optional and better

The closing PHP snippet tag at the end of the file is optional and better

WBOY
Release: 2016-08-08 09:28:08
Original
1322 people have browsed it

The PHP code segment end tag at the end of the file is optional. In some cases, it is better to omit it when using include or require so that unexpected whitespace characters will not appear at the end of the file. Response headers can still be output afterwards. It's also convenient when using output buffering, so you don't see unwanted whitespace characters generated by include files.

http://php.net/manual/zh/language.basic-syntax.instruction-separation.php

The above has introduced that the end tag of the PHP code segment at the end of the file can be omitted and is better, including aspects of the content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template