[8] ErrorException in Article.php line 112

未定义数组索引: seo_title

  1. //判断是否存在外链
  2. if($article_details['url']){
  3. echo '<script>window.location.href="'.$article_details['url'].'";</script>';exit;
  4. }
  5. //更新文章的人气
  6. $article_details_hits = db('article')->where(['id' => $article_details['id']])->update(['hits' => $article_details['hits'] + 1]);
  7. $article_details['images'] = explode(",", $article_details['images']);
  8. //设置tdk
  9. $seo_title = $article_details['seo_title'] ? $article_details['seo_title'] : $article_details['title'] . '-' . config('config.base_comlimit');
  10. $seo_keywords = $article_details['seo_keywords'] ? $article_details['seo_keywords'] : $article_details['keyword'];
  11. $seo_description = $article_details['seo_description'] ? $article_details['seo_description'] : cutstr(txt($article_details['content']),150);
  12. $this->set_system($seo_title, $seo_keywords, $seo_description);
  13. $this->assign('article_details', $article_details);
  14. //查同类
  15. $cate = db('article_category')->where(['is_check' => 1, 'id' => $article_details['cate_id']])->field('parentid,category,urlname')->find();
  16. $article_category = db('article_category')->where(['is_check' => 1, 'parentid' => $cate['parentid']])->field('id,category,urlname')->order('paixu desc')->select();

Call Stack

  1. in Article.php line 112
  2. at Error::appError(8, 'Undefined index: seo...', 'D:\wwwroot\kybz.net\...', 112, ['urlname' => 'gsdt200', 'article_category' => [['id' => 1, 'urlname' => 'gsdt', 'category' => '公司动态', ...], ['id' => 2, 'urlname' => 'cjwt', 'category' => '常见问题', ...]], 'k' => 1, ...]) in Article.php line 112
  3. at Article->details()
  4. at ReflectionMethod->invokeArgs(object(Article), []) in Container.php line 395
  5. at Container->invokeReflectMethod(object(Article), object(ReflectionMethod), ['city' => 'gsdt200', 'convert' => false]) in Module.php line 131
  6. at Module->think\route\dispatch\{closure}(object(Request), object(Closure), null)
  7. at call_user_func_array(object(Closure), [object(Request), object(Closure), null]) in Middleware.php line 185
  8. at Middleware->think\{closure}(object(Request))
  9. at call_user_func(object(Closure), object(Request)) in Middleware.php line 130
  10. at Middleware->dispatch(object(Request), 'controller') in Module.php line 136
  11. at Module->exec() in Dispatch.php line 168
  12. at Dispatch->run() in App.php line 432
  13. at App->think\{closure}(object(Request), object(Closure), null)
  14. at call_user_func_array(object(Closure), [object(Request), object(Closure), null]) in Middleware.php line 185
  15. at Middleware->think\{closure}(object(Request))
  16. at call_user_func(object(Closure), object(Request)) in Middleware.php line 130
  17. at Middleware->dispatch(object(Request)) in App.php line 435
  18. at App->run() in index.php line 29

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookiesempty
Sessionempty
Server/Request Data
ALLUSERSPROFILE C:\ProgramData
APPDATA C:\Windows\system32\config\systemprofile\AppData\Roaming
CommonProgramFiles C:\Program Files\Common Files
CommonProgramFiles(x86) C:\Program Files (x86)\Common Files
CommonProgramW6432 C:\Program Files\Common Files
COMPUTERNAME WIN-URH2HI7GTEO
ComSpec C:\Windows\system32\cmd.exe
FP_NO_HOST_CHECK NO
LOCALAPPDATA C:\Windows\system32\config\systemprofile\AppData\Local
NUMBER_OF_PROCESSORS 4
OS Windows_NT
Path C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;
PATHEXT .COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
PROCESSOR_ARCHITECTURE AMD64
PROCESSOR_IDENTIFIER Intel64 Family 6 Model 44 Stepping 2, GenuineIntel
PROCESSOR_LEVEL 6
PROCESSOR_REVISION 2c02
ProgramData C:\ProgramData
ProgramFiles C:\Program Files
ProgramFiles(x86) C:\Program Files (x86)
ProgramW6432 C:\Program Files
PSModulePath 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 WIN-URH2HI7GTEO$
USERPROFILE C:\Windows\system32\config\systemprofile
windir C:\Windows
HTTP_USER_AGENT claudebot
HTTP_ACCEPT */*
HTTP_CONNECTION close
HTTP_X_FORWARDED_FOR 3.82.232.31
HTTP_X_REAL_IP 3.82.232.31
HTTP_HOST www.kybz.net
REDIRECT_STATUS 200
SERVER_NAME 127.0.0.1
SERVER_PORT 8022
SERVER_ADDR 192.168.0.31
REMOTE_PORT 64761
REMOTE_ADDR 192.168.0.9
SERVER_SOFTWARE nginx/1.15.11
GATEWAY_INTERFACE CGI/1.1
REQUEST_SCHEME http
SERVER_PROTOCOL HTTP/1.0
DOCUMENT_ROOT D:/wwwroot/kybz.net/public
DOCUMENT_URI /index.php
REQUEST_URI /art/gsdt200.html
SCRIPT_NAME /index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD GET
QUERY_STRING s=/art/gsdt200.html
PATH_TRANSLATED D:/wwwroot/kybz.net/public
PATH_INFO
SCRIPT_FILENAME D:/wwwroot/kybz.net/public/index.php
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1711694987.9912
REQUEST_TIME 1711694987
Environment Variablesempty
ThinkPHP Constants
DS \
APP_PATH D:\wwwroot\kybz.net\public/../application/
CONF_PATH D:\wwwroot\kybz.net\public/../config/
PUBILC_PATH D:\wwwroot\kybz.net\public/
ROOT_PATH D:\wwwroot\kybz.net\public
CACHE_PATH D:\wwwroot\kybz.net\public/../runtime/
CONFIG_PATH D:\wwwroot\kybz.net\public/../config/
UPLOAD_PATH uploads