diff options
Diffstat (limited to 'mod')
-rwxr-xr-x | mod/poke.php | 24 | ||||
-rw-r--r-- | mod/settings.php | 3 |
2 files changed, 26 insertions, 1 deletions
diff --git a/mod/poke.php b/mod/poke.php index 8fe07b4cd..f4660e624 100755 --- a/mod/poke.php +++ b/mod/poke.php @@ -102,6 +102,26 @@ function poke_init(&$a) { function poke_content(&$a) { + if(! local_user()) { + notice( t('Permission denied.') . EOL); + return; + } + + $name = ''; + $id = ''; + + if(intval($_GET['c'])) { + $r = q("select id,name from contact where id = %d and uid = %d limit 1", + intval($_GET['c']), + intval(local_user()) + ); + if(count($r)) { + $name = $r[0]['name']; + $id = $r[0]['id']; + } + } + + $base = $a->get_baseurl(); $a->page['htmlhead'] .= '<script src="' . $a->get_baseurl(true) . '/library/jquery_ac/friendica.complete.js" ></script>'; @@ -141,7 +161,9 @@ EOT; '$clabel' => t('Recipient'), '$choice' => t('Choose what you wish to do to recipient'), '$verbs' => $shortlist, - '$submit' => t('Submit') + '$submit' => t('Submit'), + '$name' => $name, + '$id' => $id )); return $o; diff --git a/mod/settings.php b/mod/settings.php index ab63fa177..5e8c78ae7 100644 --- a/mod/settings.php +++ b/mod/settings.php @@ -373,6 +373,8 @@ function settings_post(&$a) { $notify += intval($_POST['notify6']); if(x($_POST,'notify7')) $notify += intval($_POST['notify7']); + if(x($_POST,'notify8')) + $notify += intval($_POST['notify8']); $email_changed = false; @@ -970,6 +972,7 @@ function settings_content(&$a) { '$notify5' => array('notify5', t('You receive a private message'), ($notify & NOTIFY_MAIL), NOTIFY_MAIL, ''), '$notify6' => array('notify6', t('You receive a friend suggestion'), ($notify & NOTIFY_SUGGEST), NOTIFY_SUGGEST, ''), '$notify7' => array('notify7', t('You are tagged in a post'), ($notify & NOTIFY_TAGSELF), NOTIFY_TAGSELF, ''), + '$notify8' => array('notify8', t('You are poked/prodded/etc. in a post'), ($notify & NOTIFY_POKE), NOTIFY_POKE, ''), '$h_advn' => t('Advanced Account/Page Type Settings'), |