Over a million developers have joined DZone.

Uploader.func.php

·
// Uploader.func.php, called by: uploader();


";
   $form .= "

Artist:

"; $form .= "

Song:

"; $form .= "

Genre:

"; $form .= "

MP3:
"; // Upload files:
"; for($x=0;$x<$num_of_uploads;$x++){ $form .= "
"; } $form .= "
Depending on the size of the MP3, this may take several minutes!

Valid file type(s): "; for($x=0;$x $value){ if($_FILES["file"]["name"][$key]!=""){ if($value==UPLOAD_ERR_OK){ $origfilename = $_FILES["file"]["name"][$key]; $filename = explode(".", $_FILES["file"]["name"][$key]); $filenameext = $filename[count($filename)-1]; unset($filename[count($filename)-1]); $filename = implode(".", $filename); // $filename = substr($filename, 0, 15).".".$filenameext; $date = date("mdY"); $time = date("His"); // $artist = $_POST['artist']; // $song = $_POST['song']; $filename = $date.$time.".".$filenameext; // $filename = $artist."-".$song.".".$filenameext; $file_ext_allow = FALSE; for($x=0;$x ".$filename."
"); }else{ echo($origfilename." was not successfully uploaded
"); } }else{ echo($origfilename." was too big, not uploaded
"); } }else{ echo($origfilename." had an invalid file extension, not uploaded
"); } }else{ echo($origfilename." was not successfully uploaded
"); } } } } } ?>

Topics:

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}