金沙城中心全部网址3983- 主頁欢迎您

[8] ErrorException in Product.php line 100

未定义数组下标: 0

  1. }else{ //如果没有子分类
  2. $havaChildren = 0;
  3. $productData = $product -> where('pcid',$cgid) -> select(); //直接获取该分类内容
  4. $this -> assign('productData',$productData);
  5. }
  6. /* 得到子分类名称及父类名称 */
  7. $parentid = getProductCatParent($cgid); //找爹
  8. $pname = $pcat -> where('pcatid',$parentid[0]) -> column('pcatname');
  9. $cname = $pcat -> where('pcatid',$cgid) -> column('pcatname');
  10. if(count($pname) == 0){ //无父类
  11. $this -> assign('pname','no');
  12. }else{
  13. $this -> assign('pname',$pname[0]);
  14. }
  15. /* 找到子栏目名称及link*/
  16. $lm = new Lanmu();

Call Stack

  1. in Product.php line 100
  2. at Error::appError(8, 'Undefined offset: 0', '/www/wwwroot/nxjinyu...', 100, ['cgid' => '79', 'pcat' => object(Pcats), 'cid' => [], ...]) in Product.php line 100
  3. at Product->category()
  4. at ReflectionMethod->invokeArgs(object(Product), []) in App.php line 229
  5. at App::invokeMethod([object(Product), 'category']) in App.php line 383
  6. at App::module(['home', 'product', 'category'], ['app_namespace' => 'app', 'app_debug' => true, 'app_trace' => false, ...], null) in App.php line 137
  7. at App::run() in start.php line 18
  8. at require('/www/wwwroot/nxjinyu...') in index.php line 38

Exception Datas

Error Context
cgid 79
pcat []
cid []
product []
havaChildren 0
productData []
parentid []

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookies
PHPSESSID iursc3dkt4d14mqg09es966cj6
Sessionempty
Server/Request Data
USER www
HOME /home/www
FCGI_ROLE RESPONDER
SCRIPT_FILENAME /www/wwwroot/nxjinyujituan.com/index.php
QUERY_STRING
REQUEST_METHOD GET
CONTENT_TYPE
CONTENT_LENGTH
SCRIPT_NAME /index.php
REQUEST_URI /index.php/home/product/category/id/79
DOCUMENT_URI /index.php/home/product/category/id/79
DOCUMENT_ROOT /www/wwwroot/nxjinyujituan.com
SERVER_PROTOCOL HTTP/1.1
REQUEST_SCHEME http
GATEWAY_INTERFACE CGI/1.1
SERVER_SOFTWARE nginx/1.14.2
REMOTE_ADDR 170.130.206.134
REMOTE_PORT 34882
SERVER_ADDR 172.24.84.215
SERVER_PORT 80
SERVER_NAME www.nxjinyujituan.com
REDIRECT_STATUS 200
PATH_INFO /home/product/category/id/79
HTTP_USER_AGENT Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)
HTTP_HOST www.nxjinyujituan.com
HTTP_ACCEPT */*
HTTP_ACCEPT_ENCODING gzip
HTTP_COOKIE PHPSESSID=iursc3dkt4d14mqg09es966cj6
PHP_SELF /index.php/home/product/category/id/79
REQUEST_TIME_FLOAT 1637187295.7248
REQUEST_TIME 1637187295
Environment Variablesempty
ThinkPHP Constants
APP_DEBUG false
APP_PATH /www/wwwroot/nxjinyujituan.com/app/
WEB_SITE /www/wwwroot/nxjinyujituan.com
PUBLIC_PATH /public/
UPLOAD_PATH /upload
TMPL_PATH /www/wwwroot/nxjinyujituan.com/template/
EXTEND_PATH /www/wwwroot/nxjinyujituan.com/extend/
ROOT
THINK_VERSION 5.0.1
THINK_START_TIME 1637187295.7253
THINK_START_MEM 263072
EXT .php
DS /
THINK_PATH /www/wwwroot/nxjinyujituan.com/thinkphp/
LIB_PATH /www/wwwroot/nxjinyujituan.com/thinkphp/library/
CORE_PATH /www/wwwroot/nxjinyujituan.com/thinkphp/library/think/
TRAIT_PATH /www/wwwroot/nxjinyujituan.com/thinkphp/library/traits/
ROOT_PATH /www/wwwroot/nxjinyujituan.com/
VENDOR_PATH /www/wwwroot/nxjinyujituan.com/vendor/
RUNTIME_PATH /www/wwwroot/nxjinyujituan.com/runtime/
LOG_PATH /www/wwwroot/nxjinyujituan.com/runtime/log/
CACHE_PATH /www/wwwroot/nxjinyujituan.com/runtime/cache/
TEMP_PATH /www/wwwroot/nxjinyujituan.com/runtime/temp/
CONF_PATH /www/wwwroot/nxjinyujituan.com/app/
CONF_EXT .php
ENV_PREFIX PHP_
IS_CLI false
IS_WIN false