©
本文檔使用 php中文網手册 發布
(PHP 4, PHP 5)
readline_list_history — 获取命令历史列表
获取整个命令行历史.
返回整个命令行历史的数组.元素的整数索引从零开始
[#1] Anonymous [2011-01-26 18:17:53]
Note this function is only available when PHP is compiled with libreadline, not if it is compiled with libedit.
<?php
if (function_exists('readline_list_history')) {
$history = readline_list_history();
// ...
} else {
echo 'Not supported by the compiled library.'.PHP_EOL;
}
?>