Skip to content

Commit

Permalink
basic-syntax.xml Specify when it is better to skip closing PHP tags
Browse files Browse the repository at this point in the history
It seemed to me that limiting the skipping of closing PHP tags to only files that contain only PHP code is misleading. After all, we skip closing tags in files with mixed content too, and the condition for skipping is not whether the file consists only of PHP code, but whether the file ends with PHP code
  • Loading branch information
mmalferov authored Dec 13, 2024
1 parent 4bf27ed commit 92cb59e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion language/basic-syntax.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
</para>

<para>
If a file contains only PHP code, it is preferable to omit the PHP closing tag
If a file ends with PHP code, it is preferable to omit the PHP closing tag
at the end of the file. This prevents accidental whitespace or new lines
being added after the PHP closing tag, which may cause unwanted effects
because PHP will start output buffering when there is no intention from
Expand Down

0 comments on commit 92cb59e

Please sign in to comment.