aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesús <heckyel@hyperbola.info>2020-12-07 17:46:03 -0500
committerJesús <heckyel@hyperbola.info>2020-12-07 17:46:03 -0500
commitd1f22bc1a0cf874e76a626dd770a201a0ee303a4 (patch)
tree8c81a8dd334c512e23aa6942eb36fdac451da297
parent17649b06f8e5c19cd0312377ff633bf079fab3c6 (diff)
downloadytlibre-d1f22bc1a0cf874e76a626dd770a201a0ee303a4.tar.lz
ytlibre-d1f22bc1a0cf874e76a626dd770a201a0ee303a4.tar.xz
ytlibre-d1f22bc1a0cf874e76a626dd770a201a0ee303a4.zip
Add streamFormatsExtra to download
-rw-r--r--index.php1
-rw-r--r--templates/video.tpl10
-rw-r--r--tools/processor.php3
3 files changed, 14 insertions, 0 deletions
diff --git a/index.php b/index.php
index 6cef35b..6379ef5 100644
--- a/index.php
+++ b/index.php
@@ -36,6 +36,7 @@ else
// Videos Loop
$video_decode->assign("streamFormats", $streamFormats);
+ $video_decode->assign("streamFormatsExtra", $streamFormatsExtra);
// Live
$video_decode->assign("islive", $islive);
diff --git a/templates/video.tpl b/templates/video.tpl
index f8155ad..ee3e9f9 100644
--- a/templates/video.tpl
+++ b/templates/video.tpl
@@ -125,6 +125,16 @@
</a>
</li>
{/foreach}
+
+ {if $streamExtra === TRUE}
+ {foreach $streamFormatsExtra as $download}
+ <li class="download-format">
+ <a class="boton-descarga" href="{$download['url']}">
+ {$download['format']}
+ </a>
+ </li>
+ {/foreach}
+ {/if}
</ul>
</details>
{else}
diff --git a/tools/processor.php b/tools/processor.php
index a490d32..5918873 100644
--- a/tools/processor.php
+++ b/tools/processor.php
@@ -47,8 +47,11 @@ $islive = $vidisLiveContent;
if (!empty($vdef)) {
$streamFormats = $vdef;
+ $streamFormatsExtra = $vid;
+ $streamExtra = TRUE;
} else {
$streamFormats = $vid;
+ $streamExtra = FALSE;
}
$videoAuthor = $vidauthor;