aboutsummaryrefslogtreecommitdiffstats
path: root/mod/poke.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-07-19 21:09:40 -0700
committerfriendica <info@friendica.com>2012-07-19 21:09:40 -0700
commitbf386749047731d3a7f47fd99f7dcc4e93ed7be7 (patch)
tree49168f1e7d3ca11f0b3622ca9129904af15608bf /mod/poke.php
parent6293c5e1cf53eeb6db487c74c6e4cec8a11148d4 (diff)
downloadvolse-hubzilla-bf386749047731d3a7f47fd99f7dcc4e93ed7be7.tar.gz
volse-hubzilla-bf386749047731d3a7f47fd99f7dcc4e93ed7be7.tar.bz2
volse-hubzilla-bf386749047731d3a7f47fd99f7dcc4e93ed7be7.zip
sync
Diffstat (limited to 'mod/poke.php')
-rwxr-xr-xmod/poke.php24
1 files changed, 23 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;