[Pkg-owncloud-commits] [owncloud] 76/121: Update public.php
David Prévot
taffit at moszumanska.debian.org
Thu Aug 21 16:44:36 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository owncloud.
commit 5dd950bc0a23702f69a72439d3b2ffc9c5b8cbe8
Author: pzy <pzy at d1sturbed.org>
Date: Mon May 19 19:53:27 2014 +0200
Update public.php
added tag to make facebook load a preview picture
Update public.php
add check ifMimeSupported and put the thumbsize in a variable
generate preview for all supported mimes
---
apps/files_sharing/templates/public.php | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/apps/files_sharing/templates/public.php b/apps/files_sharing/templates/public.php
index 8406b79..4210329 100644
--- a/apps/files_sharing/templates/public.php
+++ b/apps/files_sharing/templates/public.php
@@ -1,4 +1,9 @@
<?php /** @var $l OC_L10N */ ?>
+<?php $thumbSize=1024; ?>
+<?php if ( \OC\Preview::isMimeSupported($_['mimetype'])): /* This enables preview images for links (e.g. on Facebook, Google+, ...)*/?>
+ <link rel="image_src" href="<?php p(OCP\Util::linkToRoute( 'core_ajax_public_preview', array('x' => $thumbSize, 'y' => $thumbSize, 'file' => $_['directory_path'], 't' => $_['dirToken']))); ?>" />
+<?php endif; ?>
+
<div id="notification-container">
<div id="notification" style="display: none;"></div>
</div>
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git
More information about the Pkg-owncloud-commits
mailing list