代码拉取完成,页面将自动刷新
<?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");
$id = 0 + $_GET['torrentid'];
if (isset($CURUSER)) {
$row = mysql_fetch_array(sql_query("SELECT seedtime, uploaded FROM snatched WHERE torrentid = $id AND userid = $CURUSER[id]")); //认领时用户对该种的做种时间和上传量
$checktorrentnum = mysql_num_rows(sql_query("SELECT id FROM claim WHERE torrentid = $id AND userid = $CURUSER[id]")); //检查用户是否认领该种子
$checknum = mysql_num_rows(sql_query("SELECT id FROM claim WHERE torrentid = $id")); //检查认领该种子的人数
$checkusernum = mysql_num_rows(sql_query("SELECT id FROM claim WHERE userid = $CURUSER[id]")); //检查该用户认领数量
if ($checknum < $claimmaxnum) {
if ($checkusernum < $claimnum) {
if ($checktorrentnum != 1) {
sql_query("INSERT INTO claim (torrentid, userid, seedtime, uploaded, added) VALUE ('$id', '$CURUSER[id]', '" . (0 + $row['seedtime']) . "', '" . (0 + $row['uploaded']) . "', '" . date("Y-m-d", time()) . "')") or sqlerr(__FILE__, __LINE__);
echo "claim";
}
}
} else {
return false;
}
} else {
return false;
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。