⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tag.func.php

📁 phpcms2007很好的cms内容管理系统,操作方便
💻 PHP
字号:
<?php
function link_list($templateid = '', $typeid = '', $linktype = 0, $linknum = 100, $cols = 6, $showhits = 0)
{
	global $db,$PHP_SITEURL,$MOD;
	$showhits = intval($showhits);
	$cols = intval($cols);
	$linknum = intval($linknum);
	$linktype = intval($linktype);
	$showhits = intval($showhits);
	$condition = '';
	$condition .= " AND linktype=$linktype ";
	if($typeid)
	$condition .= "AND typeid IN ($typeid) ";
	$result = $db->query("SELECT * FROM ".TABLE_LINK." WHERE passed=1 $condition ORDER BY elite DESC,listorder ASC LIMIT $linknum " );
	if($db->affected_rows()>0)
	{
		while($r=$db->fetch_array($result))
		{	
			if(!preg_match('/http:\/\//',$r['logo']))
			{
				$r['logo'] = $PHP_SITEURL.$r['logo'];
			}
			$links[]=$r;
		}
		$width = ceil(100/$cols).'%';
		$templateid = $templateid ? $templateid : "tag_link_list";
		include template('link',$templateid);
	}
}
?>

⌨️ 快捷键说明

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