Follow along with the video below to see how to install our site as a web app on your home screen.
Бележка: This feature may not be available in some browsers.
<?php
echo '
<table width="500" border="1" cellpadding="4" cellspacing="2">
<tr>
<td>Файл</td>
<td>Големина</td>
<td>Тип</td>
<td>CHMOD</td>
<td>Качен на </td>
</tr>';
$dir = scandir('.');
$files = count( $dir );
for ( $i = 2; $i < $files; $i++ )
{
$size = filesize($dir[$i]);
$type = filetype($dir[$i]);
$chmod = substr(sprintf('%o', fileperms($dir[$i])), -4);
$time = date ("F d Y H:i:s.", filemtime($filename));
echo "
<tr>
<td><a href=\"$dir[$i]\"/>$dir[$i]</a></td>
<td>$size b</td>
<td>$type</td>
<td>$chmod</td>
<td>$time</td>
</tr>";
}
echo '</table>';
?>
??djvato каза:напиши ми го целия ... щот ми дава некви грешки
djvato каза:напиши ми го целия ... щот ми дава некви грешки
djvato каза:http://djvato.freehostia.com/kachi/
да, но гледам че си го добавил към upload файла. може там да си окецал нещоdjvato каза:както ми го даде mizarck :roll:
<div align="center">
<h1> - FREE Upload of Pictures and Files - </h1>
<img src="http://djvato.freehostia.com/freeup.gif" /><br>
<a href="http://djvato.freehostia.com/">Home</a><br>
<a href="http://djvato.freehostia.com/forum">Forum</a><br>
<a href="http://djvato.freehostia.com/zapis/form.html">Zapishi se</a><br>
<a href="http://djvato.freehostia.com/kachi">Upload File</a><br>
</div>
<center><form enctype="multipart/form-data" action="gotovo.php" method="post" >
<input type="hidden" name=:MAX_FILE_SIZE" value="999999" />
Send this file:<input type="file" name="book_image" /><br />
<input type="submit" value="Upload" />
</form> </center>
<?php
echo '
<table width="500" border="1" cellpadding="4" cellspacing="2">
<tr>
<td>Файл</td>
<td>Големина</td>
<td>Тип</td>
<td>CHMOD</td>
<td>Качен на </td>
</tr>';
$dir = scandir('.');
$files = count( $dir );
for ( $i = 2; $i < $files; $i++ )
{
$size = filesize($dir[$i]);
$type = filetype($dir[$i]);
$chmod = substr(sprintf('%o', fileperms($dir[$i])), -4);
$time = date ("F d Y H:i:s.", filemtime($filename));
echo "
<tr>
<td><a href=\"$dir[$i]\"/>$dir[$i]</a></td>
<td>$size b</td>
<td>$type</td>
<td>$chmod</td>
<td>$time</td>
</tr>";
}
echo '</table>';
?>
<?php
$max_photo_size=50000;
$upload_required=true;
$upload_page="upload.html";
$upload_dir="files/";
$err_msg=false;
do{
if(!isset($_FILES['book_image'])){$err_msg="the form was not sent in completely "; break;}
else{$book_image=$_FILES['book_image'];}
switch($book_image['error']){
case UPLOAD_ERR_INI_SIZE: $err_msg="the size of the image is too large."; break 2;
case UPLOAD_ERR_PARTIAL: $err_msg="An error ocurred while uploading the gile"; break 2;
case UPLOAD_ERR_NO_FILE: $err_msg="You nott Select a fie to be uploaded"; break 2;
case UPLOAD_ERR_FORM_SIZE: $err_msg="The size was too large";
case UPLOAD_ERR_OK: if($book_image['size'] > $max_photo_size){$err_msg="the size of the image is too large max size is $max_photo_size ";} break 2;
default: $err_msg="An unknown error occirred"; }
if(!in_array($book_image['type'], array('image/jpeg','image/pjpeg','image/png')))
{$err_msg="You need to upload a PNG or JPEG image"; break;}
}
while(0);
if(!$err_msg){
if(!@move_uploaded_file($book_image['tmp_name'], $upload_dir.$book_image['name'])){
$err_msg="Error moving the file to its distination";}}
?>
<title>Upload handler</title>
<?php
if($err_msg){
echo $err_msg;
}
else{
?>
<img src="files/<?php echo $book_image['name']; ?>" />
<?php } ?>
<div align="center">
<h1> - FREE Upload of Pictures and Files - </h1>
<img src="http://djvato.freehostia.com/freeup.gif" /><br>
<a href="http://djvato.freehostia.com/">Home</a><br>
<a href="http://djvato.freehostia.com/forum">Forum</a><br>
<a href="http://djvato.freehostia.com/zapis/form.html">Zapishi se</a><br>
<a href="http://djvato.freehostia.com/kachi">Upload File</a><br>
</div>
<center><form enctype="multipart/form-data" action="gotovo.php" method="post" >
<input type="hidden" name=:MAX_FILE_SIZE" value="999999" />
Send this file:<input type="file" name="book_image" /><br />
<input type="submit" value="Upload" />
</form> </center>
<?php
echo '
<table width="600" border="1" cellpadding="4" cellspacing="2">
<tr>
<td>Файл</td>
<td>Големина</td>
<td>Тип</td>
<td>CHMOD</td>
<td>Качен на </td>
</tr>';
$dir = scandir('.');
$files = count( $dir );
for ( $i = 2; $i < $files; $i++ )
{
$size = filesize($dir[$i]);
$type = filetype($dir[$i]);
$chmod = substr(sprintf('%o', fileperms($dir[$i])), -4);
$time = date ("F d Y H:i:s.", filemtime($filename));
echo "
<tr>
<td><a href=\"$dir[$i]\"/>$dir[$i]</a></td>
<td>$size b</td>
<td>$type</td>
<td>$chmod</td>
<td>$time</td>
</tr>";
}
echo '</table>';
?>