17 October, 2011

[script] simple url transloder version 2.0

Here this script just copy paste in your webserver

<?
error_reporting(0);
function style()
{
echo "<TITLE>Transload Version 2.0</TITLE>
<STYLE>
BODY
{
COLOR: #000000;
margin: 5,5,5,5;
FONT-FAMILY: Courier New,Courier;
}
TD
{
FONT-SIZE: 14px;
FONT-FAMILY: Courier New,Courier;
COLOR: #555555;
HEIGHT: 20;
}
A:link, A:visited, A:active
{
COLOR: #000000;
TEXT-DECORATION: none;
}
A:hover
{
COLOR: #FFFF00;
TEXT-DECORATION: none;
}
</STYLE>
";
}

$thedir="galleries/";

function url_copy($source)
{
$d=explode("/",$source);
$dest=$d[count($d)-1];
$f1=fopen($source,"rb");
$f2=fopen($dest,"w");
echo "<SCRIPT>window.status='Copying \'$source\' to \'$dest\'...';</SCRIPT>\n";
flush();
while ($buff=fread($f1,1024))
fwrite($f2,$buff);
fclose($f1);
fclose($f2);
$size=filesize($dest);
echo "<SCRIPT>window.status='$size bytes copied.';</SCRIPT>\n";
}

function list_file()
{
echo "<TABLE width=90% align=center border=1 bordercolor=#0000FF style='border-collapse: collapse' cellpadding=2>
<TR>
<TD><B>File name</B></TD>
<TD><B>File size</B></TD>
<TD><B>File time</B></TD>
</TR>";
$d=opendir(".");
while ($f=readdir($d))
if (!($f=="." || $f==".." || $f=="index.php"))
{
$size=filesize($f);
$date=filemtime($f);
echo "<TR><TD><A href=$f>$f</A></TD><TD>$size</TD><TD>".date ("H:i:s - d F Y", $date)."</TD></TR>";
}
echo "</TABLE>";
}

function show_form()
{
echo "<H3 align=center>Transload URL version 2.0<BR>
<br></H3>
<TABLE width=90% align=center border=1 bordercolor=#0000FF style='border-collapse: collapse' cellpadding=2>
<FORM method=post>
<TR>
<TD width=100% align=right valign=top><B>Tranload Url</B><BR>Put one URL or multi URL per line.<br> EX : http://domain1.com/aa.zip <br>http://domain2.com/bb.zip<br>http://domain3.com/cc.zip<br>..........................</TD>
<TD><TEXTAREA wrap=virtual name=url rows=10 cols=80></TEXTAREA></TD>
</TR>
<TR>
<TD colspan=2 align=center><INPUT type=submit value=' Transload now '></TD>
</TR>
</TABLE>
</FORM>";
}

function download()
{
header("Content-type: application/x-download");
header("Content-Disposition: attachment; filename=index.php");
@readfile("index.php");
die();
}

$cmd=$_SERVER[QUERY_STRING];
if ($cmd=="source")
download();
style();
show_form();
global $HTTP_POST_VARS;

$url=$HTTP_POST_VARS[url];
if ($url!="")
{
$d=explode("\n",$url);
$d=str_replace("\r","",$d);
for ($i=0; $i<count($d); $i++)
if (trim($d[$i])!="") url_copy($d[$i]);
}
list_file();
?>
<br>
<br>

Labels:

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home