[8] ErrorException in Product.php line 90

未定义变量: where

  1. if ($id = input('urlname')) {
  2. if(is_numeric($id)){
  3. $where['id'] = $id;
  4. }else{
  5. $where['urlname'] = $id;
  6. }
  7. }
  8. //if (input('id/d')) {
  9. $catalogName = Db::name('category')->where($where)->find();
  10. $this->view->assign('catalog', $catalogName);
  11. $thefather = Db::name('category')->where('id',$catalogName['pid'])->find();
  12. $this->view->assign('thefather',$thefather);
  13. //dump($thefather);
  14. $map['category_id'] = $catalogName['id'];
  15. $product=$this->model->where($map)->order('weigh asc')->paginate(4);
  16. $page = $product->render();
  17. $productlist=$product->toArray();
  18. foreach($productlist['data'] as $key => $value){

Call Stack

  1. in Product.php line 90
  2. at Error::appError(8, 'Undefined variable: ...', '/www/wwwroot/www.eve...', 90, ['map' => ['lang' => 'en', 'status' => 1], 'id' => null]) in Product.php line 90
  3. at Product->list()
  4. at ReflectionMethod->invokeArgs(object(Product), []) in App.php line 343
  5. at App::invokeMethod([object(Product), 'list'], []) in App.php line 598
  6. at App::module(['index', 'Product', 'list'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], true) in App.php line 456
  7. at App::exec(['type' => 'module', 'module' => 'index/Product/list'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...]) in App.php line 139
  8. at App::run() in start.php line 19
  9. at require('/www/wwwroot/www.eve...') in index.php line 17

Environment Variables

GET Data
empty
POST Data
empty
Files
empty

Cookies

lang
en
Session
empty

Server/Request Data

USER
www
HOME
/home/www
HTTP_USER_AGENT
claudebot
HTTP_ACCEPT
*/*
HTTP_HOST
www.everun.com
PATH_INFO
/product/list/id/48
REDIRECT_STATUS
200
SERVER_NAME
www.everun.com
SERVER_PORT
443
SERVER_ADDR
172.27.206.53
REMOTE_PORT
40864
REMOTE_ADDR
3.88.254.50
SERVER_SOFTWARE
nginx/1.22.1
GATEWAY_INTERFACE
CGI/1.1
HTTPS
on
REQUEST_SCHEME
https
SERVER_PROTOCOL
HTTP/2.0
DOCUMENT_ROOT
/www/wwwroot/www.everun.com/public
DOCUMENT_URI
/index.php
REQUEST_URI
/product/list/id/48
SCRIPT_NAME
/index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD
GET
QUERY_STRING
s=/product/list/id/48
SCRIPT_FILENAME
/www/wwwroot/www.everun.com/public/index.php
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1711638803.2773
REQUEST_TIME
1711638803
Environment Variables
empty

ThinkPHP Constants

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