diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2014-04-29 17:07:10 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2014-05-02 17:02:57 +0200 |
commit | 20893cc3b335049a144a53be24eaacb2e33a1480 (patch) | |
tree | c0795a4246bf6c38ec8b8ad9461e25b17ec9af74 /apps/files_sharing/templates | |
parent | 49d9631eee1616b9ae2846886c3d428236c5b81a (diff) | |
download | nextcloud-server-20893cc3b335049a144a53be24eaacb2e33a1480.tar.gz nextcloud-server-20893cc3b335049a144a53be24eaacb2e33a1480.zip |
Images on public sharing get downscaled to increase use experience - this will speed up loading time
- adding keep aspect to core/ajax/preview.php
- remove duplicate method Preview::show()
- no more hard coded mimetype of preview
- remove .png from the preview urls
- keep old route preview.png for backwards compatibility
- aspect preserving previews are now cached
Diffstat (limited to 'apps/files_sharing/templates')
-rw-r--r-- | apps/files_sharing/templates/public.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/files_sharing/templates/public.php b/apps/files_sharing/templates/public.php index f3c75134a5f..7614e122e86 100644 --- a/apps/files_sharing/templates/public.php +++ b/apps/files_sharing/templates/public.php @@ -30,7 +30,10 @@ <?php else: ?> <?php if (substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'image'): ?> <div id="imgframe"> - <img src="<?php p($_['downloadURL']); ?>" alt="" /> + <img + src="<?php p(OCP\Util::linkToRoute( 'core_ajax_public_preview', array('x' => 1000, 'y' => 1000, 'a' => 'true', 'file' => $_['directory_path'], 't' => $_['dirToken']))); ?>" + class="publicpreview" + alt=""/> </div> <?php elseif (substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'video'): ?> <div id="imgframe"> |