符号 :
在 PHP 中是什么意思?
What does the symbol :
mean in PHP?
PHP 为其某些控制结构提供了替代语法;即,if、while、for、foreach 和 switch.在每种情况下,替代语法的基本形式是分别将左大括号更改为冒号 (:),将右大括号更改为 endif;、endwhile;、endfor;、endforeach; 或 endswitch;.
PHP offers an alternative syntax for some of its control structures; namely, if, while, for, foreach, and switch. In each case, the basic form of the alternate syntax is to change the opening brace to a colon (:) and the closing brace to endif;, endwhile;, endfor;, endforeach;, or endswitch;, respectively.
这篇关于什么是“:"在 PHP 中?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!