Home >Backend Development >PHP Tutorial >What do the tags in php language mean?
Tags in programming languages are strings added to the source code for identification. Most languages treat tags as identifiers, followed by a colon for identification.
In PHP we use <?php
to indicate the beginning of the PHP identifier, then put the PHP statement and add a terminating identifier ?>
To exit PHP mode.
You can turn PHP mode on or off in the HTML file like this according to your needs.
Most embedded scripting languages are embedded in HTML and used together with HTML, such as CSS, JavaScript, PHP, ASP and JSP. (Recommended: "PHP Tutorial")
##
以<?php开始和以?>结束标记是标准风格,这是PHP推荐使用的标记风格。 以<script language="php">开始和<script>结束是长风格标记,这种标记最长,总是可用的,但我们并不常用。 以<?开始和以?>结束标记是简短风格的标记,是最简单的,但是系统管理员偶尔会禁用掉它,因为它会干扰XML文档的声明。只用通过php.ini配置文件中的指令short_open_tag打开后就可以使用。 以<%开始和以%>结束标记是ASP风格的标记,可以在php.ini配置文件设定中启用了asp_tags选项就可以使用它(默认是禁用的),习惯了ASP风格的可以使用它。Recommended to use
<?php ?> ;
The above is the detailed content of What do the tags in php language mean?. For more information, please follow other related articles on the PHP Chinese website!