if (isloggedin()) {
if ($_SESSION['user']->getGUID() != $vars['entity']->getGUID()) {
echo "<p class=\"user_menu_block_user\">"
. "<a href=\"" // we want to zap this user fro all our content ;-)
. "{$vars['url']}action/friends/userblock?usertoblock={$vars['entity']->getGUID()}\">"
. elgg_echo("userblock:zaphim")
. "</a></p>";
}
. . .
// and later
$Block = get_metadata_byname($_SESSION['user']->getGUID(), 'BLOCKED');
$Blocked = $Block->value; // bool
if ($Blocked) // we zapped him ?
header("Location: {$CONFIG->url}" ); // do not allow access -> fwd to site home page
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
thanks for the response. i'll try that out
- Previous
- 1
- 2
- Next
You must log in to post replies.