I have a VPS, on my vps,
This is my script To upload a MP3 file and Mp3 img Cover file Together. first it was worked fine but now it is not working it gives "ERR_CONNECTION_ABORTED" ERROR Please help Me on this uploading script
This is my script To upload a MP3 file and Mp3 img Cover file Together. first it was worked fine but now it is not working it gives "ERR_CONNECTION_ABORTED" ERROR Please help Me on this uploading script
PHP Code:
include 'connect.php';
if(isset($_POST['sub'])){
$t=$_POST['title'];
$a=$_POST['artist'];
$l=$_POST['lyrics'];
$m=$_POST['music'];
$c=$_POST['category'];
//code for mp3 uploading
if($_FILES['f1']['name']){
move_uploaded_file($_FILES['f1']['tmp_name'], "files/".$_FILES['f1']['name']);
$lname="files/".$_FILES['f1']['name'];
$size =$_FILES['f1']['size'];
}
//code for cover uploading
if($_FILES['f2']['name']){
move_uploaded_file($_FILES['f2']['tmp_name'], "cover/".$_FILES['f2']['name']);
$cv="cover/".$_FILES['f2']['name'];
}
$i="insert into files(title,artist,cover,lyrics,music,lname,size,c ategory)values('$t','$a','$cv','$l','$m','$lname', '$size','$c')";
if(mysqli_query($con, $i)){
echo " Your Mp3 is Uploaded successfully..! Please <b><a href='index.php'>Login!</a></b> to main Page.<br/><br/>";
}
}
Comment