1<?php
2// (c) Copyright by authors of the Tiki Wiki CMS Groupware Project
3//
4// All Rights Reserved. See copyright.txt for details and a complete list of authors.
5// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
6// $Id$
7if (strpos($_SERVER['SCRIPT_NAME'], basename(__FILE__)) != false) {
8		header('location: index.php');
9		exit;
10}
11global $user;
12if (empty($user)) {
13		return;
14}
15
16$avatar = TikiLib::lib('tiki')->get_user_avatar($user);
17
18if (! $avatar || is_array($avatar) || strpos($avatar, 'img/noavatar') !== false) {
19		// Avatar if found should be HTML
20		$action = 'avatar';
21		$smarty->assign_by_ref("force_fill_action", $action);
22}
23