代码拉取完成,页面将自动刷新
同步操作将从 安静/ajvod 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
<?php
/**
* search.php
* ==============================================
* Copy right 2013-2014 http://www.80aj.com
* ----------------------------------------------
* This is not a free software, without any authorization is not allowed to use and spread.
* ==============================================
* @param unknowtype
* @return return_type
* @author: 80aj
* @date: 2014-2-13
* @version: v1.0.0
*/
// if (is_file ( $_SERVER ['DOCUMENT_ROOT'] . '/360safe/360webscan.php' )) {
// require_once ($_SERVER ['DOCUMENT_ROOT'] . '/360safe/360webscan.php');
// }
if ($_REQUEST ['keyword']) {
$str = $_REQUEST ['keyword'];
$post = trim ( $str );
$post = strip_tags ( $post, "" ); // 清除HTML等代码
$post = ereg_replace ( "\t", "", $post ); // 去掉制表符号
$post = ereg_replace ( "\r\n", "", $post ); // 去掉回车换行符号
$post = ereg_replace ( "\r", "", $post ); // 去掉回车
$post = ereg_replace ( "\n", "", $post ); // 去掉换行
$post = ereg_replace ( " ", "", $post ); // 去掉空格
$str = ereg_replace ( "'", "", $post ); // 去掉单引号
} else {
Header ( "HTTP/1.1 301 Moved Permanently" );
Header ( "Location: index.php" );
exit ();
}
$url = 'http://www.torrentkitty.com/search/';
$keyword = urlencode ( $str );
include 'config.php';
include 'cURL.php';
include 'mysql.php';
$db = new sql_db ( $db_host, $db_user, $db_pass, $db_name );
$db->sql_query ( "insert into video_tags (tags) values('$str')" );
$curl = new cURL ();
$content = $curl->get ( $url . $keyword );
preg_match_all ( "/<tr><td class=\"name\">(.+?)<\/td><\/tr>/ms", $content, $list );
$lu_list = array ();
if (is_array ( $list [0] )) {
foreach ( $list [0] as $video_list ) {
preg_match_all ( "/<td(.[^>]*)>(.+?)<\/td>/ms", $video_list, $video_info );
preg_match ( "/href=\"magnet:(.+?)\"/ms", $video_info [2] [3], $magnet_infos );
$magnet_url = "magnet:" . $magnet_infos [1];
$video = array ();
$video ['name'] = $video_info [2] [0];
$video ['size'] = $video_info [2] [1];
$video ['date'] = $video_info [2] [2];
$video ['url'] = $magnet_url;
$db->sql_query ( "insert into video (vod_name,vod_size,vod_date,tag,url) values('" . $video ['name'] . "','" . $video ['size'] . "','" . $video ['date'] . "','$str','" . $video ['url'] . "')" );
}
}
Header ( "HTTP/1.1 301 Moved Permanently" );
Header ( "Location: index.php?keyword=$str" );
exit ();
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。