wantedfiles.php

来自「一款基于PHP的网络日记程序。WikyBlog支持:多用户的 BLOG」· PHP 代码 · 共 61 行

PHP
61
字号
<?phpdefined('WikyBlog') or die("Not an entry point...");global $pageOwner,$dbObject,$lang;$page->displayTitle = $lang['wanted_files'];$dbObject->links['?'] = $lang['wanted_files'];includeFile('search/all.php');	class queryWanted extends query{	var $tempObject;		function queryWanted(){		global $page,$dbInfo,$pageOwner,$lang,$wbTables;		$page->css2 =true;		$this->rowLimit = 50;						$this->query = 'SELECT DISTINCT SQL_CALC_FOUND_ROWS ';		$this->query .= ' `to_link`, COUNT(*) as `count` ';		$this->query .= ' FROM '.$wbTables['all_links'];		$this->query .= ' INNER JOIN '.$wbTables['all_files'].' USING(`file_id`) ';		$this->query .= ' WHERE `to_owner` = "'.wbDB::escape($pageOwner['username']).'" ';				$this->query .= ' AND !FIND_IN_SET("hidden", '.$wbTables['all_files'].'.`flags`) ';		$this->query .= ' AND !FIND_IN_SET("deleted", '.$wbTables['all_files'].'.`flags`) ';		$this->query .= ' AND `to_id` IS NULL ';				$this->query .= ' GROUP BY `to_link` ';		//$this->query .= ' HAVING COUNT(*) > '.$count;		$this->searchUrl = '/Special/'.$pageOwner['username'].'/WantedFiles';		browseSearch3($this,$lang['wanted_files']);	}		function abbrevOutput(&$row,$i){		echo '<li>';		echo wbLinks::local($row->to_link,str_replace('_',' ',$row->to_link));		echo ' &nbsp; (';		echo wbLinks::special('WhatLinksHere?to='.$row->to_link,$row->count.' links');		echo ')';		echo '</li>';	}		function mysqlFetch(&$result){		return mysql_fetch_object($result);	}	function displayPre(){		echo '<ol>';	}	function displayEmpty(){		parent::displayEmpty();		return true;	}}new queryWanted();

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?