aboutsummaryrefslogtreecommitdiff
path: root/actions/edit_multi.php
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2009-09-09 01:11:15 +0000
committerCash Costello <cash.costello@gmail.com>2009-09-09 01:11:15 +0000
commitefa3b16151f59d57b7ac8280f10b5db83c29ce97 (patch)
treeaae1120d7c2156c22cc6dd874106ce1acab08292 /actions/edit_multi.php
parent5ccb3887f61af7b670f0fafe077401529c141700 (diff)
downloadelgg-efa3b16151f59d57b7ac8280f10b5db83c29ce97.tar.gz
elgg-efa3b16151f59d57b7ac8280f10b5db83c29ce97.tar.bz2
using filename if no title given
Diffstat (limited to 'actions/edit_multi.php')
-rw-r--r--actions/edit_multi.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/actions/edit_multi.php b/actions/edit_multi.php
index 08947f1a4..92252b6dd 100644
--- a/actions/edit_multi.php
+++ b/actions/edit_multi.php
@@ -2,6 +2,7 @@
/**
* Elgg album: multi image edit action
*
+ * This is called when uploading images
*/
// Make sure we're logged in
@@ -25,8 +26,11 @@
// Convert string of tags into a preformatted array
$tagarray = string_to_tag_array($tags_array[$key]);
- //set description appropriately
- $image->title = $title_array[$key];
+ //set title appropriately
+ if ($title_array[$key])
+ $image->title = $title_array[$key];
+ else
+ $image->title = substr($image->originalfilename, 0, strrpos($image->originalfilename, '.'));
//set description appropriately
$image->description = $caption_array[$key];