PHP extract() 函数

例子 1

<?php
$a = 'Original';
$my_array = array("a" => "Cat","b" => "Dog", "c" => "Horse");
extract($my_array);
echo "\$a = $a; \$b = $b; \$c = $c";
?>

输出:

$a = Cat; $b = Dog; $c = Horse

你可能感兴趣的:(PHP,extract)