Jump to content

Recommended Posts

Hi there , this is my first post so i'm sorry if i posted to the wrong category . :) 

 

I installed youtorrent3 php search engine script in my website and the installation went okay .

 

 

But when I search for something , no results are found .. Can somebody tell me if something is wrong at search.php script ?

If needed I'll give out the whole script :-)

<?php
$q = mysql_escape_string($_REQUEST['search']);
//echo $_COOKIE["s"];
$cook = $_COOKIE["s"];
//var_dump($cook);
$tarr[] = '1:{name:"mininova", url:"http://www.mininova.org/"}';
$tarr[] = '2:{name:"bittorrent", url:"http://www.bittorrent.com/"}';
$tarr[] = '3:{name:"piratebay", url:"http://thepiratebay.se/"}';
$tarr[] = '4:{name:"sumotorrent", url:"http://www.sumotorrent.com/"}';
$tarr[] = '5:{name:"monova", url:"http://www.monova.org/"}';
$tarr[] = '6:{name:"newtorrents", url:"http://www.newtorrents.info/"}';
$tarr[] = '7:{name:"seedpeer", url:"http://www.seedpeer.com/"}';
$tarr[] = '8:{name:"legittorrents", url:"http://www.legittorrents.info/"}';
$tarr[] = '9:{name:"torrentz", url:"http://www.torrentz.com/"}';
$tarr[] = '10:{name:"mybittorrent", url:"http://www.mybittorrent.com/"}';
$tarr[] = '11:{name:"fulldls", url:"http://www.fulldls.com/"}';
$tarr[] = '12:{name:"fenopy", url:"http://fenopy.com/"}';
$tarr[] = '13:{name:"btjunkie", url:"http://www.btjunkie.org/"}';
$tarr[] = '14:{name:"rarbg", url:"http://rarbg.com/"}';

//var_dump($tarr);
//var_dump($cook);
$cook = str_replace(',,',',',$cook);
$ecook = array_unique(explode(",",$cook));
if(empty($cook)) { $ecook = array("1","2","3","4","5","6","7","8","9","10","11","12","13"); }
//var_dump($ecook);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title><?=$q?> Torrent Downloads - Find <?=$q?> Torrents</title>
	<meta http-equiv="content-type" content="text/html; charset=utf-8" />
	<meta name="description" content="Download directly <?=$q?> torrents! <?=$q?> videos, <?=$q?> music and <?=$q?> games free all very fast. Show more about <?=$q?>" />
	<meta name="keywords" content="<?=$q?>, <?=$q?> torrent, <?=$q?> torrents, <?=$q?> download, <?=$q?> torrent download, <?=$q?> video, <?=$q?> trailer, <?=$q?> episodes, <?=$q?> music, <?=$q?> song, <?=$q?> game, <?=$q?> software, <?=$q?>torrents, <?=$q?> find, <?=$q?> leech, <?=$q?> download, <?=$q?> torrents, <?=$q?> bittorrent" />
	<link href="i/style-2.css" media="screen" rel="Stylesheet" type="text/css" />
	<link rel="shortcut icon" href="i/favicon.ico" />
	<script type="text/javascript" src="i/ajax.js"></script>
	<!--[if IE]>
		<link href="i/style_ie.css" media="screen" rel="Stylesheet" type="text/css" />
	<![endif]-->
</head>
<body onload="document.search.q.focus();">
<div align="center">
	<div id="frame">
		<div id="header">
			<div id="logo"><a href="index.php"><img border="0" src="i/header_small.gif" alt="" /></a></div>
			<div id="search_small">
				<form name="search" method="get" action="search.php" class="form_search">
					<input type="text" name="search" value="<?=$q?>" class="search_input_small" />
					<input type="submit" value="Search" tabindex="0" name="search_button" class="search_button" />
				</form>
				<div id="advanced"><a onmouseover='this.style.cursor="pointer" ' onfocus='this.blur();' onclick="ajaxDo('engines');document.getElementById('popup_small').style.display = 'block' " ><span style="text-decoration: underline;">Show Advanced Options</span></a></div>
			</div>
		</div>
		<div id="popup_small">
			<div id="pop_title">Torrent Search Engine's</div>
			<div id="engines"></div>
		</div>
	<script src="scripts/1.js" type="text/javascript"></script>
	<script src="scripts/2.js" type="text/javascript"></script>
		<div id="main">
			<div id="m_left"><script type="text/javascript">
			search.string = "<?=$q?>";
			search.sites = {
<?php
//echo $cecook."ASD";
//var_dump($ecook);
$maxx = max($ecook);
$cecook = count($ecook);
foreach($ecook as $value)
{
$comma = ",";
//echo $cecook;
if($value == $cecook) { $comma = ""; }
if($value == $maxx) { $comma = ""; }

//if($value >= $cecook) { $comma = ""; }


if(!empty($value)) {

$output = $tarr[$value-1]."".$comma."\n";

if(strlen($output) > 5) {

echo $output;

}

}

}
?>
			};
			search.pagination = {0:'pagination1',1:'pagination2'};
			//search.php.resultMax 		// Items per page
			//search.php.sortColumn		// Sort on that column
			//search.php.sortOrder		// Sort order (-1 = DESC, 1 = ASC)
	</script>			<div id="search_status">
					<div id="counter"></div>
					<div id='pagination1'></div>
					<div id="status" class="status_state_1">Searching...</div>
			</div>
			<div id='categories'></div>
			<div id="search_results">
				<div id="results_show">
					<table width="750" cellspacing="0" cellpadding="0">
						<tr class="sort_head">
							<td style="width: 80px"><a id="date" href='javascript:search.sort("date")'>DATE</a></td>
							<td style="width: 390px"><a id="name" href='javascript:search.sort("name")'>NAME</a></td>
							<td style="width: 60px"><a id="size" href='javascript:search.sort("size")'>SIZE</a></td>
							<td style="width: 57px"><a id="seeds" href='javascript:search.sort("seeds")'>SEEDS</a></td>
							<td style="width: 57px"><a id="peers" href='javascript:search.sort("peers")'>PEERS</a></td>
							<td style="width: 70px"><a id="engine" href='javascript:search.sort("engine")'>ENGINE</a></td>
						</tr>
						<tr>
							<tbody id="result"></tbody>
						</tr>
					</table>
				</div>
				<div align="center"><div id="pagination2"></div></div>
			</div>
		</div>
		<div id="m_right">
			<div id="engines_active">Active Engines</div>
			<div id="sites"></div>
			<div id="engines_edit"><a onmouseover='this.style.cursor="pointer" ' onfocus='this.blur();' onclick="ajaxDo('engines');document.getElementById('popup_small').style.display = 'block'">Modify</a></div>
			<div id="top_search">Top Searches</div>
			<div id="top_search_2"><a href="search.php?search=10000+bc">10000 bc</a><br /><a href="search.php?search=french">french</a><br /><a href="search.php?search=cloverfield">cloverfield</a><br /><a href="search.php?search=axxo">axxo</a><br /><a href="search.php?search=jumper">jumper</a><br /><a href="search.php?search=2007+dvdrip">2007 dvdrip</a><br /><a href="search.php?search=21">21</a><br /><a href="search.php?search=1080p">1080p</a><br /><a href="search.php?search=lost">lost</a><br /><a href="search.php?search=2008">2008</a><br /><a href="search.php?search=720p">720p</a><br /><a href="search.php?search=mac">mac</a><br /><a href="search.php?search=family+guy">family guy</a><br /><a href="search.php?search=rambo">rambo</a><br /><a href="search.php?search=photoshop">photoshop</a><br /><a href="search.php?search=office+2008">office 2008</a><br /></div>
		</div>
	</div>
<?php
include("footer.php");
?>
</body>
</html>

Link to comment
https://forums.phpfreaks.com/topic/278817-php-search-engine-problem/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.