source/admin/article.ctrl.php

(开头部分) 4KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?php
	/**
	*Author 雷日锦 362606856@qq.com 
	*控制器自动生成
	*/
	if(!defined("ROOT_PATH")) exit("die Access ");
	class articleControl extends skymvc{
		
		public function __construct(){
			parent::__construct();
		}
		
		public function onDefault(){
			
			$url="/admin.php?m=article&a=default";
			$limit=20;
			$start=get("per_page","i");
			$type=get("type",'h');
			switch($type){
				case "new":
					$where=" status=0 ";
					$url.="&type=".$type;	
					break;
				case "pass":
					$where=" status=1 ";
					$url.="&type=".$type;	
					break;
				case "forbid":
					$where=" status=2 ";
					$url.="&type=".$type;	
					break;
				default:
					$where=" status in(0,1,2) ";
					break;
			}
			$s_recommend=get("s_recommend");
			switch($s_recommend){
				case 1:
						$where.=" AND is_recommend=1";
						$url.="&s_recommend=1";
					break;
				case 2:
						$where.=" AND is_recommend=0";
						$url.="&s_recommend=2";
					break;
			}
			$catid=get("catid","i");
			if($catid){
				$cids=M("category")->id_family($catid);
				$where.=" AND catid in("._implode($cids).") ";
			}
			$id=intval(get('id','i'));
			if($id){
				$where.=" AND id=$id";
			}
			$title=get_post('title','h');
			if($title){
				$where.=" AND title like '%{$title}%' ";
				$url.="&title=".urlencode($title);
			}
后面还有 131 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。