aboutsummaryrefslogtreecommitdiff
path: root/views/default/tidypics/forms/edit_multi.php
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2010-10-25 00:22:20 +0000
committerCash Costello <cash.costello@gmail.com>2010-10-25 00:22:20 +0000
commit893364a28955358ad259bfb75798560616ab3d49 (patch)
tree8b2ac2fb618596fed82b12c221eb7c485cbb9590 /views/default/tidypics/forms/edit_multi.php
parentda1493b95a2f0b5000a487ae373c9318c58d0b2d (diff)
downloadelgg-893364a28955358ad259bfb75798560616ab3d49.tar.gz
elgg-893364a28955358ad259bfb75798560616ab3d49.tar.bz2
supporting both basic and flash uploader
Diffstat (limited to 'views/default/tidypics/forms/edit_multi.php')
-rw-r--r--views/default/tidypics/forms/edit_multi.php23
1 files changed, 11 insertions, 12 deletions
diff --git a/views/default/tidypics/forms/edit_multi.php b/views/default/tidypics/forms/edit_multi.php
index 8c3e40242..aba6fd324 100644
--- a/views/default/tidypics/forms/edit_multi.php
+++ b/views/default/tidypics/forms/edit_multi.php
@@ -2,26 +2,25 @@
/**
* form for mass editing all uploaded images
*/
+
+$images = $vars['images'];
+$album = get_entity($images[0]->container_guid);
+
?>
<div class="contentWrapper">
<form action="<?php echo $vars['url']; ?>action/tidypics/edit_multi" method="post">
<?php
-
- $file_array = $vars['file_array'];
// make sure one of the images becomes the cover if there isn't one already
- $album_entity = get_entity($vars['album_guid']);
- if (!$album_entity->getCoverImageGuid()) {
+ if (!$album->getCoverImageGuid()) {
$no_cover = true;
}
- foreach ($file_array as $key => $file_guid) {
- $entity = get_entity($file_guid);
- $guid = $entity->guid;
- $body = $entity->description;
- $title = $entity->title;
- $tags = $entity->tags;
- $container_guid = $entity->container_guid;
+ foreach ($images as $key => $image) {
+ $guid = $image->guid;
+ $body = $image->description;
+ $title = $image->title;
+ $tags = $image->tags;
// first one is default cover if there isn't one already
if ($no_cover) {
@@ -54,7 +53,7 @@
}
?>
-<input type="hidden" name="container_guid" value="<?php echo $container_guid; ?>" />
+<input type="hidden" name="container_guid" value="<?php echo $album->guid; ?>" />
<p><input type="submit" name="submit" value="<?php echo elgg_echo('save'); ?>" /></p>
</form>
</div> \ No newline at end of file