Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [php] unikalna nazwa pliku
edi92
post
Post #1





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 5.03.2008

Ostrzeżenie: (0%)
-----


yo,
mam pełny skrypt do uploadu plików na serwer. Szukam jakiegoś skryptu który by nadawal wysyłanemu plikowi unikalną nazwe. A i czy jest możliwe usuwanie nie ściągniętych plików z serwera po X dniach?
Pozdrawiam Adam.

Ten post edytował edi92 5.03.2008, 20:00:59
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
edi92
post
Post #2





Grupa: Zarejestrowani
Postów: 4
Pomógł: 0
Dołączył: 5.03.2008

Ostrzeżenie: (0%)
-----


sory juz podaje (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
Kod
?>



<?php

require ('config.php');                                        # Include configuration file.
require ('common.php');                                        # Include common file with functions in.

?>


<html>
<head><title>..:: Darmowy hosting plików ::..</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2" />
<?php

echo("<link href='$skin' rel='stylesheet' type='text/css' />");

?>

</head>





<body>


<!--- HTML Submission Form Section --->

<!--- Master Table Start --->

<table class="main-table">
    
  <tr>
  <td class="main-table">
  
  
  <table class="logo-table">
  
  <tr>
  <td class="logo-table">
  
  <?php

  echo "<img src='$logo_file'>";

  ?>
  
  </tr>
  </td>
  
  </table>
  
  
  <table class="nav-table">
  
  <tr>
  <td class="nav-table">
  
  <span id="link" onclick="javascript: void(window.open('common.php?id=dirlist','','width=480,height=700,toolbar=no,menubar=no'));"> Lista plików</span>  ::  <span id="link" onclick="javascript: void(window.open('regulamin.html','','width=400,height=400,toolbar=no,menubar=no'));">Regulamin</span>  ::  <a href="http://www.efusian.co.uk/forum" target="_blank">FileFusian Forum</a>
  
  </td>
  </tr>
  
  </table>  
  
  
  
  <table class="upform-table">

  <tr>
  <td class="upform-table">
        
  <!--- Actual Form --->
  
  <form enctype="multipart/form-data" action"<?php print $PHP_SELF ?>" method="POST">
  <input type="hidden" name="MAX_FILE_SIZE" value="<?php echo ($max_file_size); ?>">
  <input type="file" name="fupload">
  <br><br>
  <input type="submit" value="Wyslij plik">

  <br>
  </form>
Wysyłaj±c plik akceptujesz <span id="link" onclick="javascript: void(window.open('regulamin.html','','width=400,height=400,toolbar=no,menubar=no'));">regulamin!
  <!--- End Form --->
  
  </td>
  </tr>
  
  </table>


  <table class="base-table">
  
  <tr>
  <td class="base-table">

  <?php
  
  $fileaccept = "";
  if($filetype1 != "NULL")
  {
            
  $fileaccept = $fileaccept . $filetype1;
                    
  }
        
  if($filetype2 != "NULL")
  {
            
  $fileaccept = $fileaccept . ", " . $filetype2;    
                    
  }
        
  if($filetype3 != "NULL")
  {
            
  $fileaccept = $fileaccept . ", " . $filetype3;
            
  }
        
  if($filetype4 != "NULL")
  {
            
  $fileaccept = $fileaccept . ", " . $filetype4;
                        
  }
        
  if($filetype5 != "NULL")
  {
            
  $fileaccept = $fileaccept . ", " . $filetype5;
                        
  }
  
  
  $upload_size = $max_file_size/1024000;
  
  $upload_size = round($upload_size, 1);
  
  
  echo ("Twoje IP:  <font color='FF3300'> $REMOTE_ADDR </font><a href='$logfile' target='_blank'> (View Log)</a>");
  echo ("<br>");
  echo ("Maksymalna wielkosć jednego pliku:  $upload_size <B>MB</B>");
  echo ("<br>");
  echo ("Pliki obsługiwane: $fileaccept");
  
  
  ?>
  
  </td>
  </tr>
  
  </table>
  
        
        
  </td>
  </tr>
      
</table>
    
<!--- Master Table End --->


</body>
</html>
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 2.10.2025 - 18:38