diff options
Diffstat (limited to 'views/default')
-rw-r--r-- | views/default/river/object/album/create.php | 22 | ||||
-rw-r--r-- | views/default/river/object/image/create.php | 3 | ||||
-rw-r--r-- | views/default/tidypics/forms/admin.php | 26 |
3 files changed, 43 insertions, 8 deletions
diff --git a/views/default/river/object/album/create.php b/views/default/river/object/album/create.php index 40f847c78..5f8b07965 100644 --- a/views/default/river/object/album/create.php +++ b/views/default/river/object/album/create.php @@ -6,9 +6,27 @@ $url = "<a href=\"{$performed_by->getURL()}\">{$performed_by->name}</a>";
$string = sprintf(elgg_echo("album:river:created"),$url) . " ";
$string .= "<a href=\"" . $album->getURL() . "\">" . $album->title . "</a>";
+
+ $album_river_view = get_plugin_setting('album_river_view', 'tidypics');
- if ($album->cover) {
- $string .= "<div class=\"river_content\"> <img src=\"" . $CONFIG->wwwroot . 'mod/tidypics/thumbnail.php?file_guid=' . $album->cover . '&size=thumb" border="0" class="tidypics_album_cover" alt="thumbnail"/>' . "</div>";
+ if ($album_river_view == "cover") {
+ if ($album->cover) {
+ $string .= "<div class=\"river_content\"> <img src=\"" . $CONFIG->wwwroot . 'mod/tidypics/thumbnail.php?file_guid=' . $album->cover . '&size=thumb" border="0" class="tidypics_album_cover" alt="thumbnail"/>' . "</div>";
+ }
+ } else {
+
+ $string .= "<div class=\"river_content\">";
+
+ // display the simple image views. Uses: via 'object/image.php'
+ $images = get_entities("object", "image", $file_guid, 'time_created desc', 7);
+
+ if (count($images)) {
+ foreach($images as $image){
+ $string .= "<a href=\"" . $image->getURL() . "\"> <img src=\"" . $CONFIG->wwwroot . 'mod/tidypics/thumbnail.php?file_guid=' . $image->guid . '&size=thumb" border="0" class="tidypics_album_cover" alt="thumbnail"/> </a>';
+ }
+ }
+
+ $string .= "</div>";
}
echo $string;
diff --git a/views/default/river/object/image/create.php b/views/default/river/object/image/create.php index 09320080b..8f7a856ea 100644 --- a/views/default/river/object/image/create.php +++ b/views/default/river/object/image/create.php @@ -17,7 +17,10 @@ $string = sprintf(elgg_echo("image:river:created"),$performed_by->name, $image_link, $album_link);
$string .= "<div class=\"river_content\">";
+
+/* // this adds the album cover to the river display
$string .= "<a href=\"" . $album->getURL() . "\"> <img src=\"" . $CONFIG->wwwroot . 'mod/tidypics/thumbnail.php?file_guid=' . $album->cover . '&size=thumb" border="0" class="tidypics_album_cover" alt="thumbnail"/> </a>';
+*/
$string .= "<a href=\"" . $image->getURL() . "\"> <img src=\"" . $CONFIG->wwwroot . 'mod/tidypics/thumbnail.php?file_guid=' . $image->guid . '&size=thumb" border="0" class="tidypics_album_cover" alt="thumbnail"/> </a>';
$string .= "</div>";
diff --git a/views/default/tidypics/forms/admin.php b/views/default/tidypics/forms/admin.php index d2d676290..a67d320d5 100644 --- a/views/default/tidypics/forms/admin.php +++ b/views/default/tidypics/forms/admin.php @@ -71,18 +71,32 @@ $form_body .= "<p>" . elgg_echo('tidypics:settings:quota') . "<br />";
$form_body .= elgg_view("input/text",array('internalname' => 'params[quota]', 'value' => $quota)) . "</p>";
- // River options
- $river_view = $plugin->river_view;
- if (!$river_view) $river_view = '1';
- $form_body .= '<p>' . elgg_echo('tidypics:settings:river_view');
+ // River Image options
+ $img_river_view = $plugin->img_river_view;
+ if (!$img_river_view) $img_river_view = '1';
+ $form_body .= '<p>' . elgg_echo('tidypics:settings:img_river_view');
$form_body .= elgg_view('input/pulldown', array(
- 'internalname' => 'params[river_view]',
+ 'internalname' => 'params[img_river_view]',
'options_values' => array(
'all' => 'all',
'1' => '1',
'none' => 'none',
),
- 'value' => $river_view
+ 'value' => $img_river_view
+ ));
+ $form_body .= '</p>';
+
+ // River Album options
+ $album_river_view = $plugin->album_river_view;
+ if (!$album_river_view) $album_river_view = '1';
+ $form_body .= '<p>' . elgg_echo('tidypics:settings:album_river_view');
+ $form_body .= elgg_view('input/pulldown', array(
+ 'internalname' => 'params[album_river_view]',
+ 'options_values' => array(
+ 'cover' => 'cover',
+ 'set' => 'set',
+ ),
+ 'value' => $album_river_view
));
$form_body .= '</p>';
|