* @copyright Curverider Ltd 2008-2010 * @link http://elgg.com/ * * @uses $vars['entity'] The user entity. If none specified, the current user is assumed. */ if (isloggedin()) { if ($_SESSION['user']->getGUID() != $vars['entity']->getGUID()) { $ts = time(); $token = generate_action_token($ts); if ($vars['entity']->isFriend()) { echo "

getGUID()}&__elgg_token=$token&__elgg_ts=$ts\">" . elgg_echo("friend:remove") . "

"; } else { echo "

getGUID()}&__elgg_token=$token&__elgg_ts=$ts\">" . elgg_echo("friend:add") . "

"; } } } ?>