PHP Coding For Points

[TX]-Ghost

New Member
Messages
8
Reaction score
0
Points
0
Not sure what I can use these points for but I will code php scripts for points just pm me with what you want.
 

nahsorhseda

Member
Messages
116
Reaction score
0
Points
16
credits:60

hey can you code me this script what it does is that it searches all files in the directory

but what i want it to do is search files hosted at a different server and offcourse without usung ftp ,,coz ive hosted all my media files on a another host which allows media file hosting

here IS what i want you to convert check if there some errors
PHP:
<?
echo'<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">';
echo "<html>";
echo "<head>
<meta http-equiv=\"Cache-Control\" content=\"no-cache\"/>
</head>"; ?>

<?
extract($_REQUEST); 
?>
<? include("../css.php"); ?>
<?
echo "<title>nahsorhseda</title>";
echo'<body bgcolor="#000000" text="#00FF00" link="#FFFFFF" vlink="#FF0000" alink="#FFFFFF">';
echo "<small>\n";

function search($target, $directory){

   if(is_dir($directory)){
       $direc = opendir($directory);
       while(false !== ($file = readdir($direc))){

           if($file !="." && $file != ".."){

               if(is_file($directory."/".$file)){
                   if(preg_match("/$target/i", $file)){

$size = round(filesize($directory."/".$file)/1024,1);
$rev = strrev ($file);
$exp = explode (".", $rev);
$true = strrev ($exp[0]);
$trueext = strtolower ($true);
if ($trueext=="zip" OR $trueext=="rar" OR $trueext=="gz" OR $trueext=="wav" OR $trueext=="bmp" OR $trueext=="mid" OR $trueext=="midi" OR $trueext=="sis" OR $trueext=="bmp" OR $trueext=="wbmp" OR $trueext=="mmf" OR $trueext=="png" OR $trueext=="jar" OR $trueext=="jad" OR $trueext=="exe" OR $trueext=="doc" OR $trueext=="mp3" OR $trueext=="mp4" OR $trueext=="3gp" OR $trueext=="avi" OR $trueext=="gif" OR $trueext=="jpg" OR $trueext=="jpeg" OR $trueext=="nth" OR $trueext=="thm" OR $trueext=="amr"){                                           

echo "<a href=\"$directory/$file\">$file ($size KB)</a><br/>";}
                                       }
               }else if(is_dir($directory."/".$file)){
                   search($target,$directory."/".$file);

               }

           }
       }
       closedir($direc);
   }

   return;
}


echo "<b>Search Results: </b>$search<br/>---<br/>";
search("$search", "./");


?>
<form method="POST" action="process.php">
  
  <p>search again:</p>
  
  <p><input type="text" name="q" size="20"></p>
  <p><input type="submit" value="Submit" name="B1"></p>
</form>
<? include("../menu.php"); ?>

<a href="index2.php">wallpapers home</a><br/>
<a href="http://nahsorhseda.wen9.com/Rock2.html">main home</a><br/>

<img src='http://c.wen.ru/256908.wbmp?Nahsorhsed' alt='Создай сайт! Create site!'/><br/>
</body>
</html>
 
Top