norkunas / youtube-dl-php

A PHP wrapper for youtube-dl or yt-dlp.
MIT License
456 stars 158 forks source link

Faild to download #130

Closed Dosshu closed 4 years ago

Dosshu commented 4 years ago

I am trying to run it. but getting this error, Faild to download faisalvai

norkunas commented 4 years ago

So you should properly handle the exception to see the message, it's just an example code :)

norkunas commented 4 years ago

Are you sure that H:\Yt is the executable binary file and not the directory?

norkunas commented 4 years ago

Also try to configure abslute download path to check if it works (make sure that it exists) :)

Dosshu commented 4 years ago

Please correct my problem, i am learning. `$dl->setBinPath('H:\yt\youtube-dl.exe');

$dl->setPythonPath('C:\Python\python.exe');

$dl->setDownloadPath('H:\down'); ` Errom meessage : Message :The command "C:\Python\python.exe H:\yt\youtube-dl.exe "https://www.youtube.com/watch?v=oDAw7vW7H0c" --no-playlist --ignore-config --write-info-json --continue --format=bestvideo" failed. Exit Code: 1(General error) Working directory: H:\down Output: ================ Error Output: ================ C:\Python\python.exe: can't find 'main' module in 'H:\yt\youtube-dl.exe'

Dosshu commented 4 years ago

Are you sure that H:\Yt is the executable binary file and not the directory?

What is binary file means? is it "youtube-dl.exe"?

Dosshu commented 4 years ago

Also try to configure abslute download path to check if it works (make sure that it exists) :) After setting this $dl->setDownloadPath('down/'); ) i am getting this message "Message :Unable to launch a new process."

Dosshu commented 4 years ago

Thank you, Finally i solve the problem, we should use absolute path,