Home  >  Article  >  Backend Development  >  PHP中引述(变量和函数名前加&符号)的用法

PHP中引述(变量和函数名前加&符号)的用法

WBOY
WBOYOriginal
2016-06-13 13:15:55748browse

PHP中引用(变量和函数名前加&符号)的用法
http://www.ityizhan.com/php-reference-usage/

';
echo $b;
?>

&相当于动态跟踪变量 而不是固定他的值


$a = 5;
$b = &$a;
$b="world";
echo $a;     //world
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