[8] ErrorException in Comment.php line 211

未定义数组索引: c_id

  1. $index = $planet_img[$v['gift']];
  2. $comment_list[$k]['gift'] = $gift[$index];
  3. } else {
  4. $comment_list[$k]['gift'] = '';
  5. }
  6. $comment_list[$k]['status'] = '读者';
  7. if($v['anonymous'] == 1){
  8. $anonymous = Db::name('ForumAnonymous')->where('forum_id',$list['c_id'])->find();
  9. $comment_list[$k]['user_name'] = $anonymous['anonymous_name'] ? : '匿名';
  10. $comment_list[$k]['avatar'] = $anonymous['anonymous_head'] ? : $forum_img[array_rand($forum_img)];
  11. } else {
  12. $comment_list[$k]['avatar'] = $user['avatar']; //评论人头像
  13. $comment_list[$k]['user_name'] = !empty($v['nickname']) ? $v['nickname'] : $user['nickname']; //评论人昵称
  14. }
  15. $comment_list[$k]['createtime'] = date('Y-m-d H:i:s', $v['createtime']);

Call Stack

  1. in Comment.php line 211
  2. at Error::appError(8, 'Undefined index: c_i...', '/www/wwwroot/www.yjw...', 211, ['where' => ['is_del' => 0, 'pid' => 0, 'is_long' => 1], 'login_id' => false, 'm_user' => object(User), ...]) in Comment.php line 211
  3. at Comment::getChild(['is_del' => 0, 'pid' => 0, 'is_long' => 1], false) in Acontroller.php line 526
  4. at Acontroller->a_longcomments(null)
  5. at ReflectionMethod->invokeArgs(object(Acontroller), [null]) in App.php line 343
  6. at App::invokeMethod([object(Acontroller), 'a_longcomments'], []) in App.php line 611
  7. at App::module(['home', 'acontroller', 'a_longcomments'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], false) in App.php line 456
  8. at App::exec(['type' => 'module', 'module' => ['home', 'acontroller', 'a_longcomments']], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...]) in App.php line 139
  9. at App::run() in start.php line 19
  10. at require('/www/wwwroot/www.yjw...') in index.php line 34

Environment Variables

GET Data
empty
POST Data
empty
Files
empty
Cookies
empty
Session
empty

Server/Request Data

USER
www
HOME
/home/www
HTTP_USER_AGENT
claudebot
HTTP_ACCEPT
*/*
HTTP_HOST
yjwxc.com
PATH_INFO
/home/acontroller/a_longcomments.html
REDIRECT_STATUS
200
SERVER_NAME
www.yjwxc.com
SERVER_PORT
443
SERVER_ADDR
172.21.180.252
REMOTE_PORT
39146
REMOTE_ADDR
3.90.242.249
SERVER_SOFTWARE
nginx/1.18.0
GATEWAY_INTERFACE
CGI/1.1
HTTPS
on
REQUEST_SCHEME
https
SERVER_PROTOCOL
HTTP/2.0
DOCUMENT_ROOT
/www/wwwroot/www.yjwxc.com/public
DOCUMENT_URI
/index.php
REQUEST_URI
/home/acontroller/a_longcomments.html
SCRIPT_NAME
/index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD
GET
QUERY_STRING
s=/home/acontroller/a_longcomments.html
SCRIPT_FILENAME
/www/wwwroot/www.yjwxc.com/public/index.php
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1711665242.3989
REQUEST_TIME
1711665242
Environment Variables
empty

ThinkPHP Constants

APP_PATH
/www/wwwroot/www.yjwxc.com/public/../application/
PUBILC_PATH
/
THINK_VERSION
5.0.24
THINK_START_TIME
1711665242.3991
THINK_START_MEM
394472
EXT
.php
DS
/
THINK_PATH
/www/wwwroot/www.yjwxc.com/thinkphp/
LIB_PATH
/www/wwwroot/www.yjwxc.com/thinkphp/library/
CORE_PATH
/www/wwwroot/www.yjwxc.com/thinkphp/library/think/
TRAIT_PATH
/www/wwwroot/www.yjwxc.com/thinkphp/library/traits/
ROOT_PATH
/www/wwwroot/www.yjwxc.com/
EXTEND_PATH
/www/wwwroot/www.yjwxc.com/extend/
VENDOR_PATH
/www/wwwroot/www.yjwxc.com/vendor/
RUNTIME_PATH
/www/wwwroot/www.yjwxc.com/runtime/
LOG_PATH
/www/wwwroot/www.yjwxc.com/runtime/log/
CACHE_PATH
/www/wwwroot/www.yjwxc.com/runtime/cache/
TEMP_PATH
/www/wwwroot/www.yjwxc.com/runtime/temp/
CONF_PATH
/www/wwwroot/www.yjwxc.com/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false
ADDON_PATH
/www/wwwroot/www.yjwxc.com/addons/