From c2e35d2d35a9586bd564368f39544dc487cafc12 Mon Sep 17 00:00:00 2001 From: Friendika Date: Sun, 8 May 2011 22:47:35 -0700 Subject: set permalink on uploaded photo items --- mod/photos.php | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'mod/photos.php') diff --git a/mod/photos.php b/mod/photos.php index 7f94bc520..70f21d968 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -639,6 +639,14 @@ foreach($_FILES AS $key => $val) { $item_id = item_store($arr); + if($item_id) { + q("UPDATE `item` SET `plink` = '%s' WHERE `uid` = %d AND `id` = %d LIMIT 1", + dbesc($a->get_baseurl() . '/display/' . $owner_record['nickname'] . '/' . $item_id), + intval($page_owner_uid), + intval($item_id) + ); + } + if($visible) proc_run('php', "include/notifier.php", 'wall-new', $item_id); -- cgit v1.2.3