Php file does not end? & Gt; what are the benefits? 1. Why does the php file have no ending? & Gt; what are the benefits? 2. can I arbitrarily say that all my php files will not end in the future? (If not, which pages should end and which can not end ?) Php file does not end?> What are the benefits?
1. the php file does not end?> What are the benefits?
2. can I arbitrarily say that all my php files will not end in the future? (If not, which pages should end and which can not end ?) Share To: What are the benefits ?] 1. the php file does not end?> What are the benefits? 2. can I arbitrarily say that all my php files will not end in the future? (If not, which pages should end and which can not end ?) 'Data-pics = ''>
------ Solution --------------------
1. the php file does not end?> What are the benefits?
-- Prevent unnecessary blank lines or spaces from being output
2. if you are using php and html, what should you end with?> It is necessary. Otherwise, an error is reported.
------ Solution --------------------
If not Blank lines at the end of the file will not be output. if Yes?> If there are blank lines at the end of the file, it will be output. if the output is generated before the header, the program will report an error.
------ Solution --------------------
At the end of the php file used?> Can be omitted
Note: This is not an end, but a manifestation of php's humanization.
?> The last line ending character ";" can be omitted.
Omitting the last?> After the last line of code, and all spaces, empty lines are considered as part of the program, rather than being output
This prevents html code from being embedded with a large amount of white space.
It can also prevent problems caused by the output of spaces and empty rows to functions such as headers.
------ Solution --------------------
Of course there is no problem!
If this parameter is added, problems may occur.
------ Solution --------------------
Pure PHP, how do you get the view... is it echo 'test ';...........
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.