acceptable_file_types bei uploscript...
image/jpeg|image/pjpeg sind zur zeit erlaubt..
wie kann ich da aber pdf, und eps files erlauben?
image/jpeg|image/pjpeg sind zur zeit erlaubt..
wie kann ich da aber pdf, und eps files erlauben?
// Create a new instance of the class
// for error messages in french, try: uploader('fr');
$my_uploader = new uploader($_POST['language']);
// OPTIONAL: set the max filesize of uploadable files in bytes
$my_uploader->max_filesize(15000000);
// OPTIONAL: if you're uploading images,
// you can set the max pixel dimensions
// max_image_size($width, $height)
$my_uploader->max_image_size(8000, 8000);
// UPLOAD the file
if ($my_uploader->upload( $upload_file_name,
$acceptable_file_types,
$default_extension))
{
$my_uploader->save_file($path, $mode);
}
if ($my_uploader->error)
{
echo $my_uploader->error . "<br>\n";
} else
{
// Successful upload!
print($my_uploader->file['name'] .
" wurde erfolgreich am Server gespeichert <br>");
}
// OPTIONS INCLUDE:
// text/plain
// image/gif
// image/jpeg
// image/png
// Accept ONLY gifs's
#$acceptable_file_types = "image/gifs";
// Accept GIF and JPEG files
$acceptable_file_types = "image/jpeg|image/pjpeg";
// Accept ALL files
#$acceptable_file_types = "";
application/pdf *.pdf Adobe PDF-Dateien application/postscript *.ai *.eps *.ps Adobe Postscript-Dateien
application/pdf *.pdf Adobe PDF-Dateien application/postscript *.ai *.eps *.ps Adobe Postscript-Dateien
Kommentar