From 11e8fe3085d17fed5103ddcc22a7ab411ecd114c Mon Sep 17 00:00:00 2001 From: marijus Date: Mon, 20 Oct 2014 15:05:33 +0200 Subject: more work on photos --- mod/photos.php | 20 ++++++------- view/css/mod_photos.css | 14 ++------- view/tpl/photo_view.tpl | 75 +++++++++++++++++++++++++++---------------------- 3 files changed, 53 insertions(+), 56 deletions(-) diff --git a/mod/photos.php b/mod/photos.php index 4c52c7ef7..06c566f47 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -855,16 +855,14 @@ function photos_content(&$a) { $tools = array( 'profile'=>array($a->get_baseurl() . '/profile_photo/use/'.$ph[0]['resource_id'], t('Use as profile photo')), ); - - // lock - $lock = ( ( ($ph[0]['uid'] == local_user()) && (strlen($ph[0]['allow_cid']) || strlen($ph[0]['allow_gid']) - || strlen($ph[0]['deny_cid']) || strlen($ph[0]['deny_gid'])) ) - ? t('Private Message') - : Null); - - } + // lock + $lock = ( ( (strlen($ph[0]['allow_cid']) || strlen($ph[0]['allow_gid']) + || strlen($ph[0]['deny_cid']) || strlen($ph[0]['deny_gid'])) ) + ? t('Private Photo') + : Null); + $a->page['htmlhead'] .= ''; if($prevlink) - $prevlink = array($prevlink, '') ; + $prevlink = array($prevlink, t('Previous')); $photo = array( 'href' => $a->get_baseurl() . '/photo/' . $hires['resource_id'] . '-' . $hires['scale'] . '.' . $phototypes[$hires['type']], @@ -882,7 +880,7 @@ function photos_content(&$a) { ); if($nextlink) - $nextlink = array($nextlink, ''); + $nextlink = array($nextlink, t('Next')); // Do we have an item for this photo? @@ -1122,6 +1120,8 @@ function photos_content(&$a) { '$prevlink' => $prevlink, '$nextlink' => $nextlink, '$desc' => $ph[0]['description'], + '$filename' => $ph[0]['filename'], + '$unknown' => t('Unknown'), '$tag_hdr' => t('In This Photo:'), '$tags' => $tags, '$edit' => $edit, diff --git a/view/css/mod_photos.css b/view/css/mod_photos.css index 5f8ed6124..90b70b122 100644 --- a/view/css/mod_photos.css +++ b/view/css/mod_photos.css @@ -3,19 +3,9 @@ margin-bottom: 25px; } -#photo-view-wrapper { - float:left; - min-width: 500px; - overflow: hidden; -} - -#photo-prev-link, #photo-next-link { - padding: 10px; - float: left; -} - #photo-photo { - float: left; + display: table; + margin: 0 auto; } #photo-photo-end { diff --git a/view/tpl/photo_view.tpl b/view/tpl/photo_view.tpl index 4961464dc..e7259cec2 100755 --- a/view/tpl/photo_view.tpl +++ b/view/tpl/photo_view.tpl @@ -1,39 +1,33 @@
-
-

{{$album.1}}

+
-