代码拉取完成,页面将自动刷新
<?php
require "include/bittorrent.php";
dbconn();
//Send some headers to keep the user's browser from caching the response.
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . "GMT");
header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
header("Content-Type: text/xml; charset=utf-8");
if (isset($_GET['q']) && $_GET['q'] != '') {
$searchstr = unesc(trim($_GET['q']));
$suggest_query = sql_query("SELECT keywords AS suggest, COUNT(*) AS count FROM suggest WHERE keywords LIKE " . sqlesc($searchstr . "%") . " GROUP BY keywords ORDER BY count DESC, keywords DESC LIMIT 10") or sqlerr(__FILE__, __LINE__);
$result = "";
$i = 0;
while ($suggest = mysql_fetch_array($suggest_query)) {
if (strlen($suggest['suggest']) > 25)
continue;
$result .= ($result == "" ? "" : "\r\n" ) . $suggest['suggest'] . "\r\n" . $suggest['count'];
$i++;
if ($i >= 5)
break;
}
echo $result;
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。