diff --git a/boot.php b/boot.php index e1d5cecac..5a563c991 100644 --- a/boot.php +++ b/boot.php @@ -11,7 +11,7 @@ require_once('include/cache.php'); require_once('library/Mobile_Detect/Mobile_Detect.php'); define ( 'FRIENDICA_PLATFORM', 'Friendica'); -define ( 'FRIENDICA_VERSION', '3.0.1420' ); +define ( 'FRIENDICA_VERSION', '3.0.1421' ); define ( 'DFRN_PROTOCOL_VERSION', '2.23' ); define ( 'DB_UPDATE_VERSION', 1154 ); diff --git a/include/text.php b/include/text.php index 41030e677..1c50086aa 100644 --- a/include/text.php +++ b/include/text.php @@ -1578,7 +1578,7 @@ function undo_post_tagging($s) { function fix_mce_lf($s) { $s = str_replace("\r\n","\n",$s); - $s = str_replace("\n\n","\n",$s); +// $s = str_replace("\n\n","\n",$s); return $s; } diff --git a/mod/poke.php b/mod/poke.php index 085415a76..5cd88d7e2 100644 --- a/mod/poke.php +++ b/mod/poke.php @@ -27,8 +27,8 @@ function poke_init(&$a) { if(! $contact_id) return; + $parent = ((x($_GET,'parent')) ? intval($_GET['parent']) : 0); - $private = ((x($_GET,'private')) ? intval($_GET['private']) : 0); logger('poke: verb ' . $verb . ' contact ' . $contact_id, LOGGER_DEBUG); @@ -45,6 +45,32 @@ function poke_init(&$a) { $target = $r[0]; + if($parent) { + $r = q("select uri, private, allow_cid, allow_gid, deny_cid, deny_gid + from item where id = %d and parent = %d and uid = %d limit 1", + intval($parent), + intval($parent), + intval($uid) + ); + if(count($r)) { + $parent_uri = $r[0]['uri']; + $private = $r[0]['private']; + $allow_cid = $r[0]['allow_cid']; + $allow_gid = $r[0]['allow_gid']; + $deny_cid = $r[0]['deny_cid']; + $deny_gid = $r[0]['deny_gid']; + } + } + else { + + $private = ((x($_GET,'private')) ? intval($_GET['private']) : 0); + + $allow_cid = (($private) ? '<' . $target['id']. '>' : $a->user['allow_cid']); + $allow_gid = (($private) ? '' : $a->user['allow_gid']); + $deny_cid = (($private) ? '' : $a->user['deny_cid']); + $deny_gid = (($private) ? '' : $a->user['deny_gid']); + } + $poster = $a->contact; $uri = item_new_uri($a->get_hostname(),$owner_uid); @@ -53,7 +79,7 @@ function poke_init(&$a) { $arr['uid'] = $uid; $arr['uri'] = $uri; - $arr['parent-uri'] = $uri; + $arr['parent-uri'] = (($parent_uri) ? $parent_uri : $uri); $arr['type'] = 'activity'; $arr['wall'] = 1; $arr['contact-id'] = $poster['id']; @@ -64,10 +90,10 @@ function poke_init(&$a) { $arr['author-link'] = $poster['url']; $arr['author-avatar'] = $poster['thumb']; $arr['title'] = ''; - $arr['allow_cid'] = (($private) ? '<' . $target['id']. '>' : $a->user['allow_cid']); - $arr['allow_gid'] = (($private) ? '' : $a->user['allow_gid']); - $arr['deny_cid'] = (($private) ? '' : $a->user['deny_cid']); - $arr['deny_gid'] = (($private) ? '' : $a->user['deny_gid']); + $arr['allow_cid'] = $allow_cid; + $arr['allow_gid'] = $allow_gid; + $arr['deny_cid'] = $deny_cid; + $arr['deny_gid'] = $deny_gid; $arr['last-child'] = 1; $arr['visible'] = 1; $arr['verb'] = $activity; @@ -132,12 +158,12 @@ function poke_content(&$a) { EOT; + $parent = ((x($_GET,'parent')) ? intval($_GET['parent']) : '0'); + + $verbs = get_poke_verbs(); @@ -165,6 +194,7 @@ EOT; '$clabel' => t('Recipient'), '$choice' => t('Choose what you wish to do to recipient'), '$verbs' => $shortlist, + '$parent' => $parent, '$prv_desc' => t('Make this post private'), '$submit' => t('Submit'), '$name' => $name, diff --git a/util/messages.po b/util/messages.po index a7c392bfa..d48b506d1 100644 --- a/util/messages.po +++ b/util/messages.po @@ -6,9 +6,9 @@ #, fuzzy msgid "" msgstr "" -"Project-Id-Version: 3.0.1420\n" +"Project-Id-Version: 3.0.1421\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-07-30 10:00-0700\n" +"POT-Creation-Date: 2012-07-31 10:00-0700\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/view/birthdays_reminder.tpl b/view/birthdays_reminder.tpl index a00e5c7f8..8db7d22f4 100644 --- a/view/birthdays_reminder.tpl +++ b/view/birthdays_reminder.tpl @@ -5,6 +5,6 @@ {{ for $events as $event }} $event.title $event.date {{ endfor }} - + {{ endif }} diff --git a/view/invite.tpl b/view/invite.tpl index 01a45c774..a47ef0162 100644 --- a/view/invite.tpl +++ b/view/invite.tpl @@ -23,4 +23,5 @@ $msg_text - \ No newline at end of file + + diff --git a/view/photos_upload.tpl b/view/photos_upload.tpl index c20028296..2a820d9c7 100644 --- a/view/photos_upload.tpl +++ b/view/photos_upload.tpl @@ -28,6 +28,7 @@ $permissions + diff --git a/view/poke_content.tpl b/view/poke_content.tpl index 18438787a..b9e089f5b 100644 --- a/view/poke_content.tpl +++ b/view/poke_content.tpl @@ -8,9 +8,9 @@ $clabel - - - + + + $choice @@ -24,7 +24,7 @@ $prv_desc - + diff --git a/view/theme/frost-mobile/jot-header.tpl b/view/theme/frost-mobile/jot-header.tpl index d409edea4..66a2c8796 100644 --- a/view/theme/frost-mobile/jot-header.tpl +++ b/view/theme/frost-mobile/jot-header.tpl @@ -1,5 +1,6 @@