diff options
-rw-r--r-- | mod/photos.php | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/mod/photos.php b/mod/photos.php index 01a9e5f54..81ea3901a 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -208,12 +208,13 @@ function photos_post(&$a) { $uri = item_new_uri($a->get_hostname(),get_uid()); - $r = q("INSERT INTO `item` (`uid`, `type`, `resource-id`, `contact-id`, + $r = q("INSERT INTO `item` (`uid`, `type`, `wall`, `resource-id`, `contact-id`, `owner-name`,`owner-link`,`owner-avatar`, `created`, `edited`, `changed`, `uri`, `parent-uri`, `title`, `body`, `allow_cid`, `allow_gid`, `deny_cid`, `deny_gid`) - VALUES( %d, '%s', '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' )", + VALUES( %d, '%s', %d, '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' )", intval(get_uid()), dbesc('photo'), + intval(1), dbesc($p[0]['resource-id']), intval($contact_record['id']), dbesc($contact_record['name']), @@ -345,11 +346,12 @@ function photos_post(&$a) { $uri = item_new_uri($a->get_hostname(), get_uid()); - $r = q("INSERT INTO `item` (`uid`, `type`, `resource-id`, `contact-id`,`owner-name`,`owner-link`,`owner-avatar`, `created`, + $r = q("INSERT INTO `item` (`uid`, `type`, `wall`, `resource-id`, `contact-id`,`owner-name`,`owner-link`,`owner-avatar`, `created`, `edited`, `changed`, `uri`, `parent-uri`, `title`, `body`, `allow_cid`, `allow_gid`, `deny_cid`, `deny_gid`, `visible`) - VALUES( %d, '%s', '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d )", + VALUES( %d, '%s', %d, '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d )", intval(get_uid()), dbesc('photo'), + intval(1), dbesc($photo_hash), intval($contact_record['id']), dbesc($contact_record['name']), |