[8] ErrorException in Show.php line 117

未定义数组索引: title

  1. //$category_names = Db::name('category')->where('id','in',$article['category_ids'])->column('name');
  2. //$this->view->assign('category_names',$category_names);
  3. $article['content'] = str_replace('<br>', '',$article['content']);
  4. $article['content'] = str_replace('src="../uploads','src="/uploads',$article['content']);
  5. $article['content'] = str_replace('<span style="font-size: 18px; line-height: 36px;"><br></span>', '',$article['content']);
  6. $article['content'] = str_replace('<span style="font-size: 14px;"><br></span>', '',$article['content']);
  7. $this->view->assign('article',$article);
  8. $this->view->assign('title',isset($article['seotitle'])?$article['seotitle']:$article['title']);
  9. //相关专题处理
  10. if(!$this->redis->has('topic_'.$id))
  11. {
  12. $topics = Db::name('topic')->field('id,title')->where("article_ids like '%$id%'")->select();
  13. $this->redis->set('topic_'.$id,$topics,186400);
  14. }else{
  15. $topics = $this->redis->get('topic_'.$id);

Call Stack

  1. in Show.php line 117
  2. at Error::appError(8, 'Undefined index: tit...', '/www/wwwobject/test/...', 117, ['id' => 58607, 'module_name' => 'index', 'article' => ['content' => ''], ...]) in Show.php line 117
  3. at Show->article()
  4. at ReflectionMethod->invokeArgs(object(Show), []) in App.php line 197
  5. at App::invokeMethod([object(Show), 'article'], []) in App.php line 411
  6. at App::module(['index', 'show', 'article'], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...], false) in App.php line 296
  7. at App::exec(['type' => 'module', 'module' => ['index', 'show', 'article'], 'convert' => false], ['app_host' => '', 'app_debug' => true, 'app_trace' => false, ...]) in App.php line 124
  8. at App::run() in start.php line 19
  9. at require('/www/wwwobject/test/...') in index.php line 29

Exception Datas

Error Context
id 58607
module_name index
article { "content": "" }
condition keywords like "%%"
related [ { "id": 95273, "title": "\u798f\u5efa\u6587\u65c5\u5168\u56fd\u9996\u521b\uff01\u6e05\u65b0\u798f\u5efa\u56fd\u9645\u7545\u6e38\u5361\u7cfb\u5217\u53d1\u5e03 \u60e0\u6c11\u201c\u6cd5\u5b9d\u201d\u52a9\u529b\u6587\u65c5\u6d88\u8d39", "image": "http:\/\/image.cfyys.com.cn\/17134387519731bdd7092002.jpeg", "publish_time": 1713438776 }, { "id": 95272, "title": "\u4fe1\u8fbe\u5730\u4ea7\u603b\u7ecf\u7406\u52a9\u7406\u9648\u6208\u7684\u5de5\u8d44\u6bd4\u526f\u603b\u7a46\u7ea2\u6ce2\u8fd8\u9ad8 \u8fd8\u66fe\u6bd4\u603b\u7ecf\u7406\u90fd\u9ad8", "image": "http:\/\/image.cfyys.com.cn\/1713433003275139e835a70c.jpeg", "publish_time": 1713433005 }, { "id": 95270, "title": "\ufeff\u559c\u9a6c\u62c9\u96c5\u7b2c\u56db\u6b21\u51b2\u51fbIPO \u4e3a\u626d\u4e8f\u4e3a\u76c8\u4e24\u5e74\u51cf\u5c11\u5168\u804c\u5458\u5de51700\u591a\u540d\uff1f", "image": "http:\/\/image.cfyys.com.cn\/17134291434804d0341fb95b.jpeg", "publish_time": 1713429194 }, { "id": 95269, "title": "\ufeff\u5229\u90ce\u670d\u88c5\u8d22\u52a1\u603b\u76d1\u9ec4\u660e\u6d77\u7b2c\u4e00\u5b66\u5386\u662f\u5565\uff1f19\u5c81\u8fdb\u516c\u53f8\u51fd\u6388\u6587\u51ed\uff1f", "image": "http:\/\/image.cfyys.com.cn\/17134288324717d5149b2e06.jpeg", "publish_time": 1713428852 } ]

Environment Variables

GET Data
empty
POST Data
empty
Files
empty
Cookies
empty

Session

think
{ "session_url": "\/show-list-58607.html" }

Server/Request Data

USER
www
HOME
/home/www
FCGI_ROLE
RESPONDER
SCRIPT_FILENAME
/www/wwwobject/test/cfyys.com.cn/public/index.php
QUERY_STRING
s=/show-list-58607.html
REQUEST_METHOD
GET
CONTENT_TYPE
CONTENT_LENGTH
SCRIPT_NAME
/index.php
REQUEST_URI
/show-list-58607.html
DOCUMENT_URI
/index.php
DOCUMENT_ROOT
/www/wwwobject/test/cfyys.com.cn/public
SERVER_PROTOCOL
HTTP/1.1
REQUEST_SCHEME
http
GATEWAY_INTERFACE
CGI/1.1
SERVER_SOFTWARE
nginx/1.22.0
REMOTE_ADDR
3.133.137.34
REMOTE_PORT
47036
SERVER_ADDR
192.168.0.2
SERVER_PORT
80
SERVER_NAME
www.cfyys.com.cn
REDIRECT_STATUS
200
PATH_INFO
/show-list-58607.html
HTTP_ACCEPT
*/*
HTTP_USER_AGENT
claudebot
HTTP_HOST
cfyys.com.cn
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1713454674.6533
REQUEST_TIME
1713454674
Environment Variables
empty

ThinkPHP Constants

APP_PATH
/www/wwwobject/test/cfyys.com.cn/public/../application/
THINK_VERSION
5.0.11
THINK_START_TIME
1713454674.6539
THINK_START_MEM
261440
EXT
.php
DS
/
THINK_PATH
/www/wwwobject/test/cfyys.com.cn/thinkphp/
LIB_PATH
/www/wwwobject/test/cfyys.com.cn/thinkphp/library/
CORE_PATH
/www/wwwobject/test/cfyys.com.cn/thinkphp/library/think/
TRAIT_PATH
/www/wwwobject/test/cfyys.com.cn/thinkphp/library/traits/
ROOT_PATH
/www/wwwobject/test/cfyys.com.cn/
EXTEND_PATH
/www/wwwobject/test/cfyys.com.cn/extend/
VENDOR_PATH
/www/wwwobject/test/cfyys.com.cn/vendor/
RUNTIME_PATH
/www/wwwobject/test/cfyys.com.cn/runtime/
LOG_PATH
/www/wwwobject/test/cfyys.com.cn/runtime/log/
CACHE_PATH
/www/wwwobject/test/cfyys.com.cn/runtime/cache/
TEMP_PATH
/www/wwwobject/test/cfyys.com.cn/runtime/temp/
CONF_PATH
/www/wwwobject/test/cfyys.com.cn/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false
ADDON_PATH
/www/wwwobject/test/cfyys.com.cn/addons/