aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-02-09 15:58:26 -0800
committerfriendica <info@friendica.com>2012-02-09 15:58:26 -0800
commit7b0a005441a6abc3d4c327965e86ac82d2ec4db3 (patch)
tree6a3e8ff87b05292328f6ef2533585331f252eedd /include
parent795e02aa1490f6238e6ed719a0bf3604931eec3d (diff)
downloadvolse-hubzilla-7b0a005441a6abc3d4c327965e86ac82d2ec4db3.tar.gz
volse-hubzilla-7b0a005441a6abc3d4c327965e86ac82d2ec4db3.tar.bz2
volse-hubzilla-7b0a005441a6abc3d4c327965e86ac82d2ec4db3.zip
edit post not working after plaintext editor fixes, missing some recent editor template changes
Diffstat (limited to 'include')
-rwxr-xr-xinclude/items.php16
1 files changed, 10 insertions, 6 deletions
diff --git a/include/items.php b/include/items.php
index ba95919a6..9f2cc491b 100755
--- a/include/items.php
+++ b/include/items.php
@@ -1486,7 +1486,8 @@ function consume_feed($xml,$importer,&$contact, &$hub, $datedir = 0, $pass = 0)
if(count($r)) {
if((x($datarray,'edited') !== false) && (datetime_convert('UTC','UTC',$datarray['edited']) !== $r[0]['edited'])) {
- $r = q("UPDATE `item` SET `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ $r = q("UPDATE `item` SET `title` = '%s', `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($datarray['title']),
dbesc($datarray['body']),
dbesc(datetime_convert('UTC','UTC',$datarray['edited'])),
dbesc($item_id),
@@ -1616,7 +1617,8 @@ function consume_feed($xml,$importer,&$contact, &$hub, $datedir = 0, $pass = 0)
if(count($r)) {
if((x($datarray,'edited') !== false) && (datetime_convert('UTC','UTC',$datarray['edited']) !== $r[0]['edited'])) {
- $r = q("UPDATE `item` SET `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ $r = q("UPDATE `item` SET `title` = '%s', `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($datarray['title']),
dbesc($datarray['body']),
dbesc(datetime_convert('UTC','UTC',$datarray['edited'])),
dbesc($item_id),
@@ -2167,7 +2169,8 @@ function local_delivery($importer,$data) {
if(count($r)) {
if((x($datarray,'edited') !== false) && (datetime_convert('UTC','UTC',$datarray['edited']) !== $r[0]['edited'])) {
- $r = q("UPDATE `item` SET `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ $r = q("UPDATE `item` SET `title` = '%s', `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($datarray['title']),
dbesc($datarray['body']),
dbesc(datetime_convert('UTC','UTC',$datarray['edited'])),
dbesc($item_id),
@@ -2309,7 +2312,8 @@ function local_delivery($importer,$data) {
if(count($r)) {
if((x($datarray,'edited') !== false) && (datetime_convert('UTC','UTC',$datarray['edited']) !== $r[0]['edited'])) {
- $r = q("UPDATE `item` SET `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ $r = q("UPDATE `item` SET `title` = '%s', `body` = '%s', `edited` = '%s' WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($datarray['title']),
dbesc($datarray['body']),
dbesc(datetime_convert('UTC','UTC',$datarray['edited'])),
dbesc($item_id),
@@ -2805,7 +2809,7 @@ function drop_item($id,$interactive = true) {
// delete the item
- $r = q("UPDATE `item` SET `deleted` = 1, `body` = '', `edited` = '%s', `changed` = '%s' WHERE `id` = %d LIMIT 1",
+ $r = q("UPDATE `item` SET `deleted` = 1, `title` = '', `body` = '', `edited` = '%s', `changed` = '%s' WHERE `id` = %d LIMIT 1",
dbesc(datetime_convert()),
dbesc(datetime_convert()),
intval($item['id'])
@@ -2838,7 +2842,7 @@ function drop_item($id,$interactive = true) {
// If it's the parent of a comment thread, kill all the kids
if($item['uri'] == $item['parent-uri']) {
- $r = q("UPDATE `item` SET `deleted` = 1, `edited` = '%s', `changed` = '%s', `body` = ''
+ $r = q("UPDATE `item` SET `deleted` = 1, `edited` = '%s', `changed` = '%s', `body` = '' , `title` = ''
WHERE `parent-uri` = '%s' AND `uid` = %d ",
dbesc(datetime_convert()),
dbesc(datetime_convert()),