if($novel_info){ $novel_url = $this->cms_content->content_url($novel_info, 3); $this->assign('novel_url', $novel_url); $this->assign('novel_title', $novel_info['title']); } $chapter_url = $this->cms_content->content_url($_show, 4, false); $chapter_page_url = $this->cms_content->content_url($_show, 4, true); $chapter_prev_url = str_replace('{page}', max(1, $chapter_page - 1), $chapter_page_url); $chapter_next_url = str_replace('{page}', $chapter_page + 1, $chapter_page_url); $this->assign('chapter_url', $chapter_url); $this->assign('chapter_prev_url', $chapter_prev_url); $this->assign('chapter_next_url', $chapter_next_url); $this->cms_content->table = 'cms_chapter'; $chapter_list = $this->cms_content->list_arr( array('novel_id' => $_show['novel_id']), 'id', 1, 0, 500, 500 ); if($chapter_list && count($chapter_list) > 0){ $chapter_list = array_values($chapter_list); $chapter_count = count($chapter_list); $current_index = -1; foreach($chapter_list as $index => $chapter_item){ if(isset($chapter_item['id']) && $chapter_item['id'] == $_show['id']){ $current_index = $index; break; } } if($current_index > 0){ $prev_chapter = $chapter_list[$current_index - 1]; $prev_chapter_url = isset($prev_chapter['url']) && $prev_chapter['url'] ? $prev_chapter['url'] : $this->cms_content->content_url($prev_chapter, 4); $this->assign('prev_chapter_url', $prev_chapter_url); $this->assign('prev_chapter_title', $prev_chapter['title']); } if($current_index >= 0 && $current_index < $chapter_count - 1){ $next_chapter = $chapter_list[$current_index + 1]; $next_chapter_url = isset($next_chapter['url']) && $next_chapter['url'] ? $next_chapter['url'] : $this->cms_content->content_url($next_chapter, 4); $this->assign('next_chapter_url', $next_chapter_url); $this->assign('next_chapter_title', $next_chapter['title']); } } $this->cms_content->table = $novel_table_backup; } //内容单独指定的模板 if(isset($_show['show_tpl']) && $_show['show_tpl']){ $tpl = $_show['show_tpl']; } if($_GET['mid'] == 5 || $_GET['mid'] == 6){ $page = max(1, (int)R('page','G')); $this->assign('page', $page); if($_GET['mid'] == 5 && isset($comic_list) && is_array($comic_list)){ $comic_page_url = $this->cms_content->content_url($_show, 5, true); $comic_pages = paginator::pages_prev_next($page, count($comic_list), $comic_page_url); $this->assign('pages', $comic_pages); } } $this->display($tpl); } private function _split_chapter_text($text, $max_length = 1200){ $text = trim($text); if($text === ''){ return array(); } $chunks = array(); $length = mb_strlen($text, 'UTF-8'); for($offset = 0; $offset < $length; $offset += $max_length){ $chunks[] = mb_substr($text, $offset, $max_length, 'UTF-8'); } return $chunks; } } Lecms 3.0.4 错误

错误信息

错误位置

基本信息

程序流程

SQL

$_GET

$_POST

$_COOKIE

包含文件

其他信息