<?php
$a=array(1,2,0);
foreach ($a as $v):
if($v>1):
?>
5
<?php 
endif;
endforeach;
?>

 if,foreach,while,switch,declare都有这种特殊语法(冒号开头,分号结束).

相关文章:

  • 2022-01-04
  • 2021-12-12
  • 2022-12-23
  • 2022-12-23
  • 2021-11-23
  • 2022-12-23
  • 2022-02-15
  • 2021-12-10
猜你喜欢
  • 2021-11-21
  • 2022-12-23
  • 2021-07-17
  • 2021-11-04
  • 2021-11-16
相关资源
相似解决方案