gpt4 book ai didi

php apc_fetch 所有 id

转载 作者:可可西里 更新时间:2023-11-01 12:30:59 29 4
gpt4 key购买 nike

有没有办法获取和打印存储在 apc 存储中的所有数据?

出于测试和调试目的,我需要这样做。

我知道我可以通过执行 apc_fetch(id) 来检索特定数据,但我不知道有什么方法可以通过传递(例如)* 来检索所有数据

最佳答案

是的,你可以用 APCIterator 得到这个.这使您可以遍历使用 APC 存储的所有项目。

$iter = new APCIterator('user');
foreach ($iter as $item) {
echo $item['key'] . ': ' . $item['value'];
}

关于php apc_fetch 所有 id,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10798452/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com