[8] ErrorException in Product.php line 96

未定义变量: rtn

  1. $res=Db('product')->select($id);
  2. $this->assign("con",$res);
  3. // var_dump($res);
  4. // 栏目
  5. $res1=Db::table('product')->select();
  6. foreach ($res1 as $k => $v) {
  7. $rtn[]=$res1[$k]['lanmu'];
  8. }
  9. $rtn=array_unique($rtn);
  10. foreach ($rtn as $k1 => $v1) {
  11. $where=["lanmu"=>$rtn[$k1] ];
  12. $da=Db::table('product')->where($where)->select();
  13. $rtn[$k1]=$da;
  14. $rtn[$k1]['lm']=$v1;
  15. }
  16. $this->assign("listz",$rtn);
  17. return $this->fetch('xq');
  18. }

Call Stack

  1. in Product.php line 96
  2. at Error::appError(8, 'Undefined variable: ...', 'D:\wwwroot\wenquan20...', 96, ['id' => '92', 'res' => [], 'res1' => []]) in Product.php line 96
  3. at Product->proxq()
  4. at ReflectionMethod->invokeArgs(object(Product), []) in App.php line 343
  5. at App::invokeMethod([object(Product), 'proxq'], []) in App.php line 606
  6. at App::module(['index', 'product', 'proxq'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], null) in App.php line 457
  7. at App::exec(['type' => 'module', 'module' => ['index', 'product', 'proxq']], ['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('D:\wwwroot\wenquan20...') in index.php line 58

Environment Variables

GET Data

id
92
POST Data
empty
Files
empty
Cookies
empty
Session
empty

Server/Request Data

_FCGI_X_PIPE_
\\.\pipe\IISFCGI-7a11dfb8-b1b1-44b2-a805-edcb50abb16c
PHP_FCGI_MAX_REQUESTS
1000
PHPRC
C:\php_54
ALLUSERSPROFILE
C:\ProgramData
APPDATA
C:\Windows\system32\config\systemprofile\AppData\Roaming
APP_POOL_CONFIG
C:\inetpub\temp\apppools\wenquan2019\wenquan2019.config
APP_POOL_ID
wenquan2019
CommonProgramFiles
C:\Program Files (x86)\Common Files
CommonProgramFiles(x86)
C:\Program Files (x86)\Common Files
CommonProgramW6432
C:\Program Files\Common Files
COMPUTERNAME
EBS-21912
ComSpec
C:\Windows\system32\cmd.exe
DriverData
C:\Windows\System32\Drivers\DriverData
LOCALAPPDATA
C:\Windows\system32\config\systemprofile\AppData\Local
NUMBER_OF_PROCESSORS
8
OS
Windows_NT
Path
C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\php_52;D:\mysql\bin;c:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps
PATHEXT
.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
PROCESSOR_ARCHITECTURE
x86
PROCESSOR_ARCHITEW6432
AMD64
PROCESSOR_IDENTIFIER
Intel64 Family 6 Model 63 Stepping 2, GenuineIntel
PROCESSOR_LEVEL
6
PROCESSOR_REVISION
3f02
ProgramData
C:\ProgramData
ProgramFiles
C:\Program Files (x86)
ProgramFiles(x86)
C:\Program Files (x86)
ProgramW6432
C:\Program Files
PSModulePath
C:\Program Files\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules
PUBLIC
C:\Users\Public
SystemDrive
C:
SystemRoot
C:\Windows
TEMP
C:\Windows\TEMP
TMP
C:\Windows\TEMP
USERDOMAIN
WORKGROUP
USERNAME
EBS-21912$
USERPROFILE
C:\Windows\system32\config\systemprofile
windir
C:\Windows
ORIG_PATH_INFO
/index.php/index/product/proxq.html
URL
/index.php
SERVER_SOFTWARE
Microsoft-IIS/10.0
SERVER_PROTOCOL
HTTP/1.1
SERVER_PORT_SECURE
0
SERVER_PORT
80
SERVER_NAME
www.hnrzwq.com
SCRIPT_NAME
/index.php
SCRIPT_FILENAME
D:\wwwroot\wenquan2019\wwwroot\index.php
REQUEST_URI
/index.php/index/product/proxq.html?id=92
REQUEST_METHOD
GET
REMOTE_USER
REMOTE_PORT
61493
REMOTE_HOST
127.0.0.1
REMOTE_ADDR
127.0.0.1
QUERY_STRING
id=92
PATH_TRANSLATED
D:\wwwroot\wenquan2019\wwwroot\index.php\index\product\proxq.html
PATH_INFO
/index/product/proxq.html
LOGON_USER
LOCAL_ADDR
127.0.0.1
INSTANCE_META_PATH
/LM/W3SVC/10499
INSTANCE_NAME
WENQUAN2019
INSTANCE_ID
10499
HTTPS_SERVER_SUBJECT
HTTPS_SERVER_ISSUER
HTTPS_SECRETKEYSIZE
HTTPS_KEYSIZE
HTTPS
off
GATEWAY_INTERFACE
CGI/1.1
DOCUMENT_ROOT
D:\wwwroot\wenquan2019\wwwroot
CONTENT_TYPE
CONTENT_LENGTH
0
CERT_SUBJECT
CERT_SERIALNUMBER
CERT_ISSUER
CERT_FLAGS
CERT_COOKIE
AUTH_USER
AUTH_PASSWORD
AUTH_TYPE
APPL_PHYSICAL_PATH
D:\wwwroot\wenquan2019\wwwroot\
APPL_MD_PATH
/LM/W3SVC/10499/ROOT
IIS_UrlRewriteModule
7,1,1993,2336
WEBSOCKET_VERSION
13
HTTP_X_FORWARDED_PROTO
http
HTTP_X_REAL_IP
118.123.10.155
HTTP_X_FORWARDED_FOR
175.29.67.14
HTTP_USER_AGENT
Mozilla/5.0+(compatible;+Baiduspider/2.0;++http://www.baidu.com/search/spider.html)
HTTP_HOST
www.hnrzwq.com
HTTP_ACCEPT_ENCODING
gzip
HTTP_ACCEPT
*/*
HTTP_CONNECTION
close
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php/index/product/proxq.html
REQUEST_TIME_FLOAT
1604044403.2454
REQUEST_TIME
1604044403
Environment Variables
empty

ThinkPHP Constants

APP_DEBUG
true
APP_PATH
D:\wwwroot\wenquan2019\wwwroot/home/
THINK_VERSION
5.0.22
THINK_START_TIME
1604044403.2495
THINK_START_MEM
159208
EXT
.php
DS
\
THINK_PATH
D:\wwwroot\wenquan2019\wwwroot\thinkphp\
LIB_PATH
D:\wwwroot\wenquan2019\wwwroot\thinkphp\library\
CORE_PATH
D:\wwwroot\wenquan2019\wwwroot\thinkphp\library\think\
TRAIT_PATH
D:\wwwroot\wenquan2019\wwwroot\thinkphp\library\traits\
ROOT_PATH
D:\wwwroot\wenquan2019\wwwroot\
EXTEND_PATH
D:\wwwroot\wenquan2019\wwwroot\extend\
VENDOR_PATH
D:\wwwroot\wenquan2019\wwwroot\vendor\
RUNTIME_PATH
D:\wwwroot\wenquan2019\wwwroot\runtime\
LOG_PATH
D:\wwwroot\wenquan2019\wwwroot\runtime\log\
CACHE_PATH
D:\wwwroot\wenquan2019\wwwroot\runtime\cache\
TEMP_PATH
D:\wwwroot\wenquan2019\wwwroot\runtime\temp\
CONF_PATH
D:\wwwroot\wenquan2019\wwwroot/home/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
true