]> source.dussan.org Git - nextcloud-server.git/commitdiff
reintroduce download button on public shares
authorThomas Müller <thomas.mueller@tmit.eu>
Tue, 29 Apr 2014 13:28:35 +0000 (15:28 +0200)
committerThomas Müller <thomas.mueller@tmit.eu>
Tue, 29 Apr 2014 13:28:35 +0000 (15:28 +0200)
apps/files_sharing/templates/public.php

index fc8d59e1e892a82f02686c22248ee7a11098fd33..cbf7827456ee7cb4d66e38fba6d930ffeb819bbc 100644 (file)
@@ -1,3 +1,4 @@
+<?php /** @var $l OC_L10N */ ?>
 <div id="notification-container">
        <div id="notification" style="display: none;"></div>
 </div>
                                                                                                          src="<?php print_unescaped(image_path('', 'logo-wide.svg')); ?>" alt="<?php p($theme->getName()); ?>" /></a>
                <div id="logo-claim" style="display:none;"><?php p($theme->getLogoClaim()); ?></div>
                <div class="header-right">
-                       <span id="details"><?php p($l->t('shared by %s', array($_['displayName']))) ?></span>
+                       <a href="<?php p($_['downloadURL']); ?>" id="download" class="button">
+                               <img class="svg" alt="" src="<?php print_unescaped(OCP\image_path("core", "actions/download.svg")); ?>"/>
+                               <?php p($l->t('Download %s', array($_['filename'])))?>
+                       </a>
                </div>
 </div></header>
 <div id="content">
@@ -24,7 +28,7 @@
                <?php else: ?>
                        <?php if (substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'image'): ?>
                                <div id="imgframe">
-                                       <img src="<?php p($_['downloadURL']); ?>" />
+                                       <img src="<?php p($_['downloadURL']); ?>" alt="" />
                                </div>
                        <?php elseif (substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'video'): ?>
                                <div id="imgframe">
                        <?php else: ?>
                                <div id="imgframe">
                                        <?php $size = \OC\Preview::isMimeSupported($_['mimetype']) ? 500 : 128 ?>
-                                       <img src="<?php p(OCP\Util::linkToRoute( 'core_ajax_public_preview', array('x' => $size, 'y' => $size, 'file' => $_['directory_path'], 't' => $_['dirToken']))); ?>" class="publicpreview"/>
+                                       <img
+                                               src="<?php p(OCP\Util::linkToRoute( 'core_ajax_public_preview', array('x' => $size, 'y' => $size, 'file' => $_['directory_path'], 't' => $_['dirToken']))); ?>"
+                                               class="publicpreview"
+                                               alt="" />
                                </div>
                        <?php endif; ?>
                        <div class="directDownload">