item voting tools

This commit is contained in:
friendica
2015-02-10 19:10:18 -08:00
parent 79da33dafd
commit 79223b6b3d
10 changed files with 63 additions and 3 deletions

View File

@@ -59,6 +59,8 @@ function item_post(&$a) {
$api_source = ((x($_REQUEST,'api_source') && $_REQUEST['api_source']) ? true : false);
$consensus = intval($_REQUEST['consensus']);
// 'origin' (if non-zero) indicates that this network is where the message originated,
// for the purpose of relaying comments to other conversation members.
// If using the API from a device (leaf node) you must set origin to 1 (default) or leave unset.
@@ -683,6 +685,9 @@ function item_post(&$a) {
$item_flags = $item_flags | ITEM_THREAD_TOP;
}
if($consensus)
$item_flags |= ITEM_CONSENSUS;
if ((! $plink) && ($item_flags & ITEM_THREAD_TOP)) {
$plink = z_root() . '/channel/' . $channel['channel_address'] . '/?f=&mid=' . $mid;
}