Home >Backend Development >PHP Tutorial > php语法分单引号,双引号么?解决方法

php语法分单引号,双引号么?解决方法

WBOY
WBOYOriginal
2016-06-13 12:40:44844browse

php语法分单引号,双引号么?

本帖最后由 u011523116 于 2013-08-01 20:12:13 编辑
<br />
//a.php<br />
<?php<br />
print'AAA';       //用单引号,语法对!<br />
echo'BBB';       //用单引号,语法对!<br />
?><br />


<br />
<?php<br />
//b.php<br />
printf'CCC';     //用单引号,错误!<br />
?><br />


1.a.php,两句语句都是对,为什么?
php语言,不区分单引号与双引号么?

2.b.php,这句语句是错,为什么?
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