In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
This article introduces what are several marks of PHP script, the content is very detailed, interested friends can refer to, hope to be helpful to you.
What we are going to introduce to you today is the knowledge about PHP scripts. I hope it will be helpful to the students who are new to the PHP language and improve our understanding of the PHP language.
1. There are four kinds of tags in PHP scripts: short tags and asp tags are convenient, but their portability and popularity are poor, and they are usually not recommended. Also note that if you embed PHP into XML or XHTML, you need to use standard tags
< ?php ?>To keep up with the standards.
A, standard label:
< ?php .. ?>B, script label:
< script language="php">...
< /script>C, short label:
< ? … ?>You need to set short _ open_tag=on in php.ini, which defaults to on, or adds the-enable-short-tags option when PHP is compiled. (the PHP 3 version can also activate the use of short tags through the short_tags () function.)
D, asp tag (supported after PHP version 3.0.4): you need to set asp_tags=on in php.ini. Default is off.
2, PHP script instruction delimiter: like CMagnejava or Perl, PHP needs to end the instruction with a semicolon after each statement except the last line (because the closing tag implies a semicolon). Omitting the semicolon at the end of the file facilitates the use of output buffering and include () or require ()
3, PHP script comments: PHP supports comments in both CJE and Unix Shell style (Perl style). For example:
One-line comment: / /, #
Multiline comments: / * /
< ?php echo "This is a test"; // 单行注释 (c++ 风格), /* 多行注释:单行注释说明1:"// ?>"medium? > valid, single-line comment 2:" / /
< /script>"in
< /script>Invalid * / echo "This is yet another test"; echo "One Final Test"; # single-line comments (shell style)? > this is the end of what are several tags for PHP scripts. I hope the above can be helpful and learn more. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.