Members   Search      Help    Register    Login    Home
Home » Discussion Forums » Site Feed Back » pretime(can anyone mod this for phpmybitorrent)
pretime [message #4462] Thu, 15 July 2010 08:20 Go to next message
firefly007 is currently offline firefly007  South Africa
Messages: 79
Registered: May 2010
Seeder
hello there i have this piece of code from tbdev i was wondering if it is possible to mod it for phpmybitorrent. it will show the pretime for each torrent
function ago($seconds){
$day=date("j",$seconds)-1;
$month=date("n",$seconds)-1;
$year=date("Y",$seconds)-1970;
$hour=date("G",$seconds)-1;
$minute=(int) date("i",$seconds);
$returnvalue=false;
if($year){
if($year==1) $return[]="1 year"; else $return[]="$year years";
}
if($month){
if($month==1) $return[]="1 month"; else $return[]="$month months";
}
if($day){
if($day==1) $return[]="1 day"; else $return[]="$day days";
}
if($hour){
if($hour==1) $return[]="1 hour"; else $return[]="$hour hours";
}
if($minute&&$minute!=00){
if($minute==1){
$return[]="1 minute";
}else{
$return[]="$minute minutes";
}
}
for($i=0;$i<count($return);$i++){
if(!$returnvalue){
$returnvalue=$return[$i];
}elseif($i<count($return)-1){
$returnvalue.= ", ".$return[$i];
}else{
$returnvalue.= " and ".$return[$i];
}
}
return $returnvalue;

}

function getpre($name, $type)
{
$pre['regexp'] = "|<td>(.*)<td>(.*)<td>(.*)</table>|";
$pre['url'] = "http://doopes.com/?cat=454647&lang=0&num=2&mode=0&from=&to=&exc=&inc=" . $name . "&opt=0";
$pre['file'] = @file_get_contents($pre['url']);
preg_match($pre['regexp'], $pre['file'], $pre['matches']);
/**
* Types:
* 1 = Time
* 2 = Category
* 3 = Realesename
*/
return $pre['matches'][$type];
}  


[Updated on: Thu, 15 July 2010 08:21]

Report message to a moderator

Re: pretime [message #4476 is a reply to message #4462] Thu, 15 July 2010 21:10 Go to previous messageGo to next message
Daffy is currently offline Daffy  France
Messages: 359
Registered: October 2009
Location: uk
Releaser

you sites flash shows up like pic below mate. you need to edit.

          width="1200" height="800" align="left"


http://i25.tinypic.com/x3br53.jpg


Re: pretime [message #4528 is a reply to message #4462] Thu, 22 July 2010 23:15 Go to previous messageGo to next message
firefly007 is currently offline firefly007  South Africa
Messages: 79
Registered: May 2010
Seeder
hey duffy any ideas on the pre time?

Re: pretime [message #4530 is a reply to message #4528] Fri, 23 July 2010 00:12 Go to previous message
joeroberts is currently offline joeroberts  United States
Messages: 1971
Registered: June 2006
Location: U.S.A
Releaser
Da HacKer
this is not the requist section!!
Please post in proper loction.


http://a.imageshack.us/img831/5562/mybikes.png
Previous Topic:hey
Next Topic:www.ceylonbay.net
Goto Forum:
  


Current Time: Wed Feb 08 06:01:16 GMT 2012

Total time taken to generate the page: 0.00712 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software