mirror of https://github.com/friendica/friendica
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
476 B
PHTML
18 lines
476 B
PHTML
13 years ago
|
<?php
|
||
|
|
||
|
function can_write_wall(&$a,$owner) {
|
||
|
if((! (local_user())) && (! (remote_user())))
|
||
|
return false;
|
||
|
if((local_user()) && ($_SESSION['uid'] == $owner))
|
||
|
return true;
|
||
|
|
||
|
$r = q("SELECT * FROM `contact` WHERE `uid` = %d AND `id` = %d AND `blocked` = 0",
|
||
|
intval($owner),
|
||
|
intval($_SESSION['visitor_id'])
|
||
|
);
|
||
|
if(count($r))
|
||
|
return true;
|
||
|
return false;
|
||
|
|
||
|
}
|