Skip to content
This repository has been archived by the owner on Jul 12, 2020. It is now read-only.

Commit

Permalink
improve Web UI
Browse files Browse the repository at this point in the history
  • Loading branch information
Art4 committed Sep 13, 2017
1 parent 032a6d5 commit 3c58fc4
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 23 deletions.
4 changes: 2 additions & 2 deletions css/custom.css
Expand Up @@ -21,8 +21,8 @@ body {
margin-bottom: 8px; margin-bottom: 8px;
} }
.btn-type { .btn-type {
min-width: 125px; min-width: 175px;
} }
.btn-download { .btn-download {
min-width: 190px; min-width: 100px;
} }
33 changes: 12 additions & 21 deletions templates/getvideo.php
Expand Up @@ -30,53 +30,44 @@
<ul class="dl-list"> <ul class="dl-list">
<?php foreach($this->get('streams', []) as $format) { ?> <?php foreach($this->get('streams', []) as $format) { ?>
<li> <li>
<a class="btn btn-default btn-type disabled" href="#"><?php echo $format['type']; ?> - <?php echo $format['quality']; ?></a>
<?php if ($format['show_direct_url'] === true) { ?> <?php if ($format['show_direct_url'] === true) { ?>
<a class="btn btn-default btn-type" href="<?php echo $format['direct_url']; ?>" class="mime"><?php echo $format['type']; ?></a> <a class="btn btn-default btn-download" href="<?php echo $format['direct_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Direct</a>
<?php }
else
{ ?>
<span class="mime"><?php echo $format['type']; ?></span>
<?php } ?> <?php } ?>

<?php if ($format['show_proxy_url'] === true) { ?> <?php if ($format['show_proxy_url'] === true) { ?>
<a class="btn btn-primary btn-download" href="<?php echo $format['proxy_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Download - <?php echo $format['size']; ?></a> <a class="btn btn-primary btn-download" href="<?php echo $format['proxy_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Proxy</a>
<?php } ?> <?php } ?>
<div class="label label-warning">quality: <?php echo $format['quality']; ?></div> <div class="label label-warning"><?php echo $format['size']; ?></div>
</li> </li>
<?php } ?> <?php } ?>
</ul> </ul>
<hr /> <hr />
<h2>Separated video and audio format</h2> <h2>Separated video and audio format</h2>
<ul class="dl-list"> <ul class="dl-list">
<?php foreach($this->get('formats', []) as $format) { ?> <?php foreach($this->get('formats', []) as $format) { ?>
<li> <li>
<a class="btn btn-default btn-type disabled" href="#"><?php echo $format['type']; ?> - <?php echo $format['quality']; ?></a>
<?php if ($format['show_direct_url'] === true) { ?> <?php if ($format['show_direct_url'] === true) { ?>
<a class="btn btn-default btn-type" href="<?php echo $format['direct_url']; ?>" class="mime"><?php echo $format['type']; ?></a> <a class="btn btn-default btn-download" href="<?php echo $format['direct_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Direct</a>
<?php }
else
{ ?>
<span class="mime"><?php echo $format['type']; ?></span>
<?php } ?> <?php } ?>

<?php if ($format['show_proxy_url'] === true) { ?> <?php if ($format['show_proxy_url'] === true) { ?>
<a class="btn btn-primary btn-download" href="<?php echo $format['proxy_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Download - <?php echo $format['size']; ?></a> <a class="btn btn-primary btn-download" href="<?php echo $format['proxy_url']; ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Proxy</a>
<?php } ?> <?php } ?>
<div class="label label-warning">quality: <?php echo $format['quality']; ?></div> <div class="label label-warning"><?php echo $format['size']; ?></div>
</li> </li>
<?php } ?> <?php } ?>
</ul> </ul>
<?php if ($this->get('showMP3Download', false) === true) { ?> <?php if ($this->get('showMP3Download', false) === true) { ?>
<h2>Convert and Download to .mp3</h2> <h2>Convert and Download to .mp3</h2>
<ul class="dl-list"> <ul class="dl-list">
<li> <li>
<a class="btn btn-default btn-type disabled" href="#" class="mime">audio/mp3</a> <a class="btn btn-default btn-type disabled" href="#" class="mime">audio/mp3 - <?php echo $this->get('mp3_download_quality'); ?></a>
<a class="btn btn-primary btn-download" href="<?php echo $this->get('mp3_download_url'); ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Convert and Download</a> <a class="btn btn-primary btn-download" href="<?php echo $this->get('mp3_download_url'); ?>" class="mime"><i class="glyphicon glyphicon-download-alt"></i> Convert and Download</a>
<div class="label label-warning">quality: <?php echo $this->get('mp3_download_quality'); ?></div>
</li> </li>
</ul> </ul>
<?php } ?> <?php } ?>
<hr /> <hr />
<p><small>Note that you initiate download either by clicking video format link or click "download" to use this server as proxy.</small></p> <p><small>Note that you initiate download either by clicking "Direct" to download from the origin server or by clicking "Proxy" to use this server as proxy.</small></p>
<?php if ($this->get('showBrowserExtensions', false) === true) { ?> <?php if ($this->get('showBrowserExtensions', false) === true) { ?>
<p><a href="ytdl.user.js" class="userscript btn btn-mini" title="Install chrome extension to view a 'Download' link to this application on Youtube video pages."> Install Chrome Extension </a></p> <p><a href="ytdl.user.js" class="userscript btn btn-mini" title="Install chrome extension to view a 'Download' link to this application on Youtube video pages."> Install Chrome Extension </a></p>
<?php } ?> <?php } ?>
Expand Down

0 comments on commit 3c58fc4

Please sign in to comment.