Home  >  Article  >  Backend Development  >  PHP错误代码 Parse error: syntax error, unexpected解决方法

PHP错误代码 Parse error: syntax error, unexpected解决方法

PHP中文网
PHP中文网Original
2016-06-13 12:40:592116browse

  Parse error: syntax error, unexpected T_STRING in C:\AppServ\www\1.php on line 3

<?php
    
$s=array(&#39;你好&#39;,&#39;我好&#39;,&#39;大家好&#39;);
  
   shuffle($s); 
       
   for($i=0;$i<=2;$i++){
       echo $s[$i];
   echo &#39;
&#39;;
   }
   
   
    
?>

出现标题中的错误,怎么办哦?



------解决方案--------------------

$s=array(&#39;你好&#39;,&#39;我好&#39;,&#39;大家好&#39;);


分号写错了 ,应该是";" 不是";" 一切都要英文的啊 


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