aboutsummaryrefslogtreecommitdiff
path: root/mod/file/views/default/icon
diff options
context:
space:
mode:
authorcash <cash.costello@gmail.com>2011-11-05 17:09:34 -0400
committercash <cash.costello@gmail.com>2011-11-05 17:09:34 -0400
commitfa0dbc7f8a34597345f7939ca9914438624c3cee (patch)
tree70f499175aeae36f48a72c9393a520004c4aa7fe /mod/file/views/default/icon
parent558f03f0f84a142438de9844b2047be2f050c385 (diff)
downloadelgg-fa0dbc7f8a34597345f7939ca9914438624c3cee.tar.gz
elgg-fa0dbc7f8a34597345f7939ca9914438624c3cee.tar.bz2
Fixes #3567 standardized classes for icons
Diffstat (limited to 'mod/file/views/default/icon')
-rw-r--r--mod/file/views/default/icon/object/file.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/mod/file/views/default/icon/object/file.php b/mod/file/views/default/icon/object/file.php
index 51a4469e9..a3190310b 100644
--- a/mod/file/views/default/icon/object/file.php
+++ b/mod/file/views/default/icon/object/file.php
@@ -5,6 +5,7 @@
* @uses $vars['entity'] The entity the icon represents - uses getIconURL() method
* @uses $vars['size'] topbar, tiny, small, medium (default), large, master
* @uses $vars['href'] Optional override for link
+ * @uses $vars['img_class'] Optional CSS class added to img
* @uses $vars['link_class'] Optional CSS class added to link
*/
@@ -25,8 +26,13 @@ if (isset($vars['href'])) {
}
$class = '';
+if (isset($vars['img_class'])) {
+ $class = $vars['img_class'];
+}
if ($entity->thumbnail) {
- $class = 'class="elgg-photo"';
+ $class = "class=\"elgg-photo $class\"";
+} else if ($class) {
+ $class = "class=\"$class\"";
}
$img_src = $entity->getIconURL($vars['size']);