mirror of
https://github.com/friendica/friendica
synced 2024-11-20 04:23:40 +00:00
poke privacy
This commit is contained in:
parent
43d986cab2
commit
0ff93edeee
2 changed files with 12 additions and 5 deletions
12
mod/poke.php
12
mod/poke.php
|
@ -28,6 +28,8 @@ function poke_init(&$a) {
|
|||
return;
|
||||
|
||||
|
||||
$private = ((x($_GET,'private')) ? intval($_GET['private']) : 0);
|
||||
|
||||
logger('poke: verb ' . $verb . ' contact ' . $contact_id, LOGGER_DEBUG);
|
||||
|
||||
|
||||
|
@ -62,13 +64,14 @@ function poke_init(&$a) {
|
|||
$arr['author-link'] = $poster['url'];
|
||||
$arr['author-avatar'] = $poster['thumb'];
|
||||
$arr['title'] = '';
|
||||
$arr['allow_cid'] = $a->user['allow_cid'];
|
||||
$arr['allow_gid'] = $a->user['allow_gid'];
|
||||
$arr['deny_cid'] = $a->user['deny_cid'];
|
||||
$arr['deny_gid'] = $a->user['deny_gid'];
|
||||
$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['last-child'] = 1;
|
||||
$arr['visible'] = 1;
|
||||
$arr['verb'] = $activity;
|
||||
$arr['private'] = $private;
|
||||
$arr['object-type'] = ACTIVITY_OBJ_PERSON;
|
||||
|
||||
$arr['origin'] = 1;
|
||||
|
@ -162,6 +165,7 @@ EOT;
|
|||
'$clabel' => t('Recipient'),
|
||||
'$choice' => t('Choose what you wish to do to recipient'),
|
||||
'$verbs' => $shortlist,
|
||||
'$prv_desc' => t('Make this post private'),
|
||||
'$submit' => t('Submit'),
|
||||
'$name' => $name,
|
||||
'$id' => $id
|
||||
|
|
|
@ -23,7 +23,10 @@
|
|||
</select>
|
||||
<br />
|
||||
<br />
|
||||
|
||||
<div id="poke-private-desc">$prv_desc</div>
|
||||
<input type="checkbox" name="private" value="1" />
|
||||
<br />
|
||||
<br />
|
||||
<input type="submit" name="submit" value="$submit" />
|
||||
</form>
|
||||
|
||||
|
|
Loading…
Reference in a new issue