1, 修改文件 / phpcms/modules/content/templates/content_list.tpl.PHP.
打开文件大约在 50 行添加:
代码如下:
<option value='4' <?PHP if($_GET['searchtype']==4) echo 'selected';?>> 内容 </option>
2, 在修改文件 phpcms/modules/content/content.PHP.
打开文件大约在 90 行添加:
代码如下:
- elseif($searchtype==4){
- $searchtype = $type_array[$searchtype];
- $keyword = strip_tags(trim($_GET['keyword']));
- $where = "id in(select id from".$this->db->db_tablepre.$this->db->model[$modelid]
- ['tablename']."_data where `content` like'%".$keyword."%')";
- }
3, 效果如图:
来源: http://www.bubuko.com/infodetail-3019273.html