Home > Backend Development > PHP Tutorial > php Parse error: syntax error, unexpected end of file

php Parse error: syntax error, unexpected end of file

WBOY
Release: 2016-07-29 09:00:41
Original
4228 people have browsed it

When using xampp’s wordpress, when following the new theme, the following error occurred:

Parse error: syntax error, unexpected end of file. .

Then I found the file according to the prompts, and then the error always said that the last line was wrong. I found the last line and found that php did not end normally, that is,

?>

or

?>

I still got the same error after adding it. It took me a long time to find the problem, which is to turn on php short tag.

The specific method is to search for short_open_tag in the php.ini file

and change it to short_open_tag=On. If it is already On, it means that the short tag has been turned on, and there is no need to set it anymore


php Parse error: syntax error, unexpected end of file

The above has introduced php Parse error: syntax error, unexpected end of file, including the relevant 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