PHPis a webprogramming language. During the programming process, you will inevitably encounter using echo to output large sections of html andjavascriptIn the case of scripts, if you use thePHPtraditional output method-output by string, there must be a large number ofescape charactersto correct the characters in the string. Escapespecial characterssuch as quotation marks to avoidsyntax errors. If it is one or two places, it can be tolerated, but if it is a complete html text or a 200-line js, I think everyone will collapse. This is whyPHPintroduces a delimiter - at least a large part of the reason.
1. The function of the PHP delimiter is to output the things inside it as it is, including newline format and so on;
2. Anything in the PHP delimiter Special characters do not need to be escaped; the
PHP variablein the3.PHP delimiter will be replaced with its value normally.
The delimiter format in PHP is this:
//top:作用使得整个frameset都跳转 window.top.location.href = "$group_url/Manager/login"; eof; echo $js;
PHP Chinese websiteSearch
Related recommendations:
#php How to get remote image downloads and save them locally
PHP Export EXCEL Quick Development Guide
The above is the detailed content of PHP delimiter <<