Hello I am stacked in uploading video files using javascript/angularJS. firstly I used to PHP while uploading. but it get failed when large amount of video is uploading. someone says it will be helpful if you use chunking in it. I am looking for a library built for specially for Javascript/Angular js that may able to upload to FTP also.
Thanks in advance.
Below code is used for PHP upload. (failed when large amount of videos is uploading. eg. 1-2GB)
$ftp_server = ftp_server;
$ftp_user_name= ftp_user_name;
$ftp_user_pass= ftp_user_pass;
$file = $_FILES["photo"]["tmp_name"];
$remote_file = $file_name;
$conn_id = ftp_connect($ftp_server) or die("Couldn't connect to $ftp_server");
$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
ftp_pasv($conn_id, true);
if ( ftp_put($conn_id, $remote_file, $file, FTP_BINARY) ) {
echo "Success";
} else {
echo ""Failed;
}