04c03-1.php
来自「介绍PHP5的给类型函数应用」· PHP 代码 · 共 21 行
PHP
21 行
<?phpfunction print_alias($alias) { static $number_of_aliases = 1; // Output this alias and increment the counter echo "{$number_of_aliases}. {$alias}\n"; $number_of_aliases++;}// Call the function multiple times.// Each time it increments the count and the output will be:// 1. Eli// 2. HyPeR aCtIvE// 3. THL Siegfried Sebastian Faustecho '<pre>';print_alias('Eli');print_alias('HyPeR aCtIvE');print_alias('THL Siegfried Sebastian Faust');echo '</pre>';?>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?