[8] ErrorException in common.php line 51

未定义数组索引: cate_id

  1. // 获取详情URL
  2. function getShowUrl($v)
  3. {
  4. if ($v) {
  5. // var_dump($v['id']);
  6. //$home_rote[''.$v['catdir'].'-:cat/:id'] = 'home/'.$v['catdir'].'/index';
  7. $cate = \think\facade\Db::name('cate')
  8. ->field('id,catdir,moduleid')
  9. ->where('id', $v['cate_id'])
  10. ->find();
  11. $moduleurl = \think\facade\Db::name('module')
  12. ->where('id', $cate['moduleid'])
  13. ->value('name');
  14. if ($cate['catdir']) {
  15. $url = url($cate['catdir'] . '/'.$v['xqbt']);
  16. } else {
  17. $url = empty($v['jumpurl'])?url($moduleurl . '/info', ['cate' => $cate['id'], 'id' => $v['id']]):$v['jumpurl'];
  18. }

Call Stack

  1. in common.php line 51
  2. at Error->appError(8, 'Undefined index: cat...', '/web/wwwroot/www.jer...', 51, ['v' => ['table_con' => []]]) in common.php line 51
  3. at getShowUrl(['table_con' => []]) in Error.php line 115
  4. at Error->info()
  5. at ReflectionMethod->invokeArgs(object(Error), []) in Container.php line 355
  6. at Container->invokeReflectMethod(object(Error), object(ReflectionMethod), ['id' => 'CatC15SpacerPlate']) in Controller.php line 105
  7. at Controller->think\route\dispatch\{closure}(object(Request)) in Pipeline.php line 59
  8. at Pipeline->think\{closure}(object(Request)) in Pipeline.php line 65
  9. at Pipeline->then(object(Closure)) in Controller.php line 108
  10. at Controller->exec() in Dispatch.php line 103
  11. at Dispatch->run() in Route.php line 765
  12. at Route->think\{closure}(object(Request)) in Pipeline.php line 59
  13. at Pipeline->think\{closure}(object(Request)) in SessionInit.php line 64
  14. at SessionInit->handle(object(Request), object(Closure), null)
  15. at call_user_func([object(SessionInit), 'handle'], object(Request), object(Closure), null) in Middleware.php line 126
  16. at Middleware->think\{closure}(object(Request), object(Closure)) in Pipeline.php line 84
  17. at Pipeline->think\{closure}(object(Request)) in Pipeline.php line 65
  18. at Pipeline->then(object(Closure)) in Route.php line 766
  19. at Route->dispatch(object(Request), object(Closure)) in Http.php line 202
  20. at Http->dispatchToRoute(object(Request)) in Http.php line 193
  21. at Http->runWithRequest(object(Request)) in Http.php line 148
  22. at Http->run() in index.php line 20

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookiesempty
Sessionempty
Server/Request Data
USER www
HOME /home/www
HTTP_REFERER http://www.jereh-powertech.com/NewProducts/CatC15SpacerPlate.html
HTTP_USER_AGENT claudebot
HTTP_ACCEPT */*
HTTP_HOST www.jereh-powertech.com
PATH_INFO
REDIRECT_STATUS 200
SERVER_NAME www.jereh-powertech.com
SERVER_PORT 443
SERVER_ADDR 172.20.51.208
REMOTE_PORT 34426
REMOTE_ADDR 44.200.210.43
SERVER_SOFTWARE nginx/1.24.0
GATEWAY_INTERFACE CGI/1.1
HTTPS on
REQUEST_SCHEME https
SERVER_PROTOCOL HTTP/2.0
DOCUMENT_ROOT /web/wwwroot/www.jereh-powertech.com/public
DOCUMENT_URI /index.php
REQUEST_URI /NewProducts/CatC15SpacerPlate.html
SCRIPT_NAME /index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD GET
QUERY_STRING s=/NewProducts/CatC15SpacerPlate.html
SCRIPT_FILENAME /web/wwwroot/www.jereh-powertech.com/public/index.php
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1711640206.1318
REQUEST_TIME 1711640206
Environment Variablesempty
ThinkPHP Constants
PHP_OS_FAMILY Linux