PHP标签
1. Standard Tags
标准形式
<?phpecho'ABC'; ?>
2. Short Tags
立即学习“PHP免费学习笔记(深入)”;
需要在php.ini中设置short_open_tag = On
<?echo'ABC'; ?>
3. Echo Short Tags
短标签输出的简写形式
PHP5.4及以上版本使用这种形式不再需要设置short_open_tag
<?='ABC'; ?><?='A','B','C'; ?>
4. ASP-Style Tags
需要在php.ini中设置asp_tags = On
PHP7已废除,不再使用
<% echo'ABC'; %>
5. Echo ASP-Style Tags
需要在php.ini中设置asp_tags = On
PHP7已废除,不再使用
<%='ABC'; %>
6. Script Tags
PHP7已废除,不再使用
<script language="php">echo'ABC';</script>
PHP注释
1. 单行C++风格
// This is a one-line c++ style comment
2. 单行shell风格
# This is a one-line shell-style comment
3. 多行注释
/* This is a multi line comment yet another line of comment */
').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i ').text(i)); }; $numbering.fadeIn(1700); }); });
以上就介绍了PHP Tags & Comments - PHP标签和注释,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。











