Skip to content

Commit

Permalink
Get embed videos too
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel authored and daniel committed Mar 9, 2021
1 parent e5e4c16 commit b7910cf
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions objects/Encoder.php
Original file line number Diff line number Diff line change
Expand Up @@ -1841,6 +1841,7 @@ static function getDurationFromLink($link) {
}

static function getThumbsFromLink($link, $returnFileName = false) {
$link = str_replace(array('"', "'"), array('', ''), $link);
$tmpfname = tempnam(sys_get_temp_dir(), 'thumbs');
$cmd = self::getYouTubeDLCommand() . " --no-check-certificate --no-playlist --force-ipv4 --write-thumbnail --skip-download -o \"{$tmpfname}.jpg\" \"{$link}\"";
exec($cmd . " 2>&1", $output, $return_val);
Expand Down

0 comments on commit b7910cf

Please sign in to comment.