array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'zh', ), 'this' => array ( 0 => 'function.spl-autoload-extensions.php', 1 => 'spl_autoload_extensions', ), 'up' => array ( 0 => 'ref.spl.php', 1 => 'SPL 函数', ), 'prev' => array ( 0 => 'function.spl-autoload-call.php', 1 => 'spl_autoload_call', ), 'next' => array ( 0 => 'function.spl-autoload-functions.php', 1 => 'spl_autoload_functions', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'zh', 'path' => 'reference/spl/functions/spl-autoload-extensions.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 5 >= 5.1.0, PHP 7, PHP 8)
spl_autoload_extensions — 注册并返回 spl_autoload 的默认文件扩展名
逗号分隔的 spl_autoload() 的默认文件扩展名。
版本 | 说明 |
---|---|
8.0.0 |
file_extensions 现在可以为 null。
|
示例 #1 spl_autoload_extensions() 示例
<?php
spl_autoload_extensions(".php,.inc");
?>