From ad4f0fc6c003e0b3365f542795c1c6b3ee06749d Mon Sep 17 00:00:00 2001 From: cash Date: Mon, 2 Jan 2012 15:40:23 -0500 Subject: displaying the labels on tags now --- views/default/photos/css.php | 24 ++++++++++++++++++++---- views/default/photos/tagging/tag.php | 18 +++++++++++++++--- views/default/photos/tagging/tags.php | 3 +++ 3 files changed, 38 insertions(+), 7 deletions(-) (limited to 'views/default/photos') diff --git a/views/default/photos/css.php b/views/default/photos/css.php index 23926adbc..3e18d1908 100644 --- a/views/default/photos/css.php +++ b/views/default/photos/css.php @@ -23,13 +23,20 @@ .tidypics-gallery-widget > li { width: 100%; } - +/* +.tidypics-lightbox { + margin: 0 auto; + display: block; + width: auto; +} +*/ +/* .tidypics-photo { margin: 0 auto; display: block; } - -.tidypics-wrapper-photo { +*/ +.tidypics-photo-wrapper { position: relative; } @@ -116,10 +123,19 @@ max-width: 300px; } -.tidypics-tag { +.tidypics-tag-wrapper { display: none; position: absolute; +} + +.tidypics-tag { border: 2px solid white; + clear: both; +} + +.tidypics-tag-label { + float: left; + margin-top: 5px; } coords . '}'); @@ -15,10 +18,19 @@ $attributes = elgg_format_attributes(array( 'data-height' => $coords->height, )); -//var_dump($vars['tag']); -//$text = "This is a something"; +if ($vars['tag']->type == 'user') { + $user = get_entity($vars['tag']->value); + $label = elgg_view('output/url', array( + 'text' => $user->name, + 'href' => $user->getURL(), + )); +} else { + $label = $vars['tag']->value; +} echo << +
+
+
$label
HTML; diff --git a/views/default/photos/tagging/tags.php b/views/default/photos/tagging/tags.php index 7a4aa3a59..29c9d0efb 100644 --- a/views/default/photos/tagging/tags.php +++ b/views/default/photos/tagging/tags.php @@ -3,6 +3,9 @@ * View the tags for this image * * @uses $vars['entity'] + * + * @author Cash Costello + * @license http://www.gnu.org/licenses/gpl-2.0.html GNU General Public License v2 */ $tags = $vars['entity']->getPhotoTags(); -- cgit v1.2.3