diff options
author | Simon L'nu <simon.lnu@gmail.com> | 2012-05-21 21:23:40 -0400 |
---|---|---|
committer | Simon L'nu <simon.lnu@gmail.com> | 2012-05-21 21:23:40 -0400 |
commit | 867e3b33d11a8403ce2d7eda567b8eb7ba58bda7 (patch) | |
tree | 1a91309205c5659516b0a7daab0d478db82b846a /mod/photos.php | |
parent | f570965ebe65fe7d549cafea5f5d8c04da3d986f (diff) | |
parent | 9ca3ac6e61ff57a2bc615b133a64b0a7f66b3c41 (diff) | |
download | volse-hubzilla-867e3b33d11a8403ce2d7eda567b8eb7ba58bda7.tar.gz volse-hubzilla-867e3b33d11a8403ce2d7eda567b8eb7ba58bda7.tar.bz2 volse-hubzilla-867e3b33d11a8403ce2d7eda567b8eb7ba58bda7.zip |
Merge branch 'master', remote-tracking branch 'remotes/upstream/master'
* remotes/upstream/master:
rev update, bug 428, 429, and ability to block globaldir submissions from demo sites
* master:
Diffstat (limited to 'mod/photos.php')
-rw-r--r-- | mod/photos.php | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/mod/photos.php b/mod/photos.php index 8da94841e..082947bdb 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -977,9 +977,16 @@ function photos_content(&$a) { $tpl = get_markup_template('photo_album.tpl'); if(count($r)) + $twist = 'rotright'; foreach($r as $rr) { + if($twist == 'rotright') + $twist = 'rotleft'; + else + $twist = 'rotright'; + $o .= replace_macros($tpl,array( '$id' => $rr['id'], + '$twist' => ' ' . $twist . rand(2,4), '$photolink' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/image/' . $rr['resource-id'], '$phototitle' => t('View Photo'), '$imgsrc' => $a->get_baseurl() . '/photo/' . $rr['resource-id'] . '-' . $rr['scale'] . '.jpg', @@ -1400,9 +1407,16 @@ function photos_content(&$a) { $photos = array(); if(count($r)) { + $twist = 'rotright'; foreach($r as $rr) { + if($twist == 'rotright') + $twist = 'rotleft'; + else + $twist = 'rotright'; + $photos[] = array( 'id' => $rr['id'], + 'twist' => ' ' . $twist . rand(2,4), 'link' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/image/' . $rr['resource-id'], 'title' => t('View Photo'), 'src' => $a->get_baseurl() . '/photo/' . $rr['resource-id'] . '-' . ((($rr['scale']) == 6) ? 4 : $rr['scale']) . '.jpg', |