$maxFileSize) { echo "Error: File size exceeds 30MB limit."; } else { $video_name = $video['name']; $video_tmp = $video['tmp_name']; // Get the file extension $file_extension = strtolower(pathinfo($video_name, PATHINFO_EXTENSION)); // Check for .mov extension if ($file_extension === 'mov') { echo "Error: .mov files are not accepted."; } else { // Move the uploaded file to the target directory if (move_uploaded_file($video_tmp, "../../images/video/" . $video_name)) { // Insert the video name into the database $query = "INSERT INTO `video`(`video`) VALUES ('$video_name')"; $result = mysqli_query($con, $query); if ($result) { header('location: video.php'); } else { echo "Database insertion error."; } } else { echo "Error: Could not move the uploaded file."; } } } } ?> Admin
ADD VIDEO
Video - DETAILS
Id
Video Url
Action
delete