Home >Backend Development >PHP Problem >How to solve the problem of php delimiter error

How to solve the problem of php delimiter error

藏色散人
藏色散人Original
2022-01-21 09:42:001438browse

Solution to php delimiter error: 1. Open the corresponding PHP code file; 2. Place the cursor on the next line, with code such as "echo <<

How to solve the problem of php delimiter error

The operating environment of this article: Windows 7 system, PHP version 7.1, DELL G3 computer

How to solve the problem of php delimiter error?

An error occurred in the PHP delimiter

Parse error: syntax error, unexpected end of file, expecting variable (T_VARIABLE) or heredoc end (T_END_HEREDOC) or ${ (T_DOLLAR_OPEN_CURLY_BRACES) or {$ (T_CURLY_OPEN)

In class today, errors were reported in the sports delimiters Heredoc and Nowdoc. In the end, I found that even after writing the following Delimiter, you must also keep the cursor on the next line to solve the problem

  echo <<<ABC
  45645646465
  ABC;

Recommended learning: "PHP Video Tutorial"

The above is the detailed content of How to solve the problem of php delimiter error. For more information, please follow other related articles on the PHP Chinese website!

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