<commit_before>{* $Id$ *}
{capture assign="viewuser"}{$userwatch|escape:"url"}{/capture}
{title url="tiki-user_information.php?view_user=$viewuser"}{tr}User Information{/tr}{/title}

{if "$userwatch" eq "$user" }
	{include file='tiki-mytiki_bar.tpl'}
{/if}

{if $prefs.feature_tabs neq 'y' and $user and $prefs.feature_messages eq 'y' and $tiki_p_messages eq 'y' and $allowMsgs eq 'y'}
	<div class="t_navbar">
		{button href="#message" class="btn btn-default" _text="{tr}Send me a message{/tr}"}
	</div>
{/if}

{tabset name="user_information"}
	{tab name="{tr}Basic Data{/tr}"}
		{if $infoPublic eq 'y'}
			<h2>{$userinfo.login}</h2>
			<div class="clearfix">
				<div class="pull-right">
					{if $tiki_p_admin eq 'y' or $userinfo.login eq $user}
						{if $tiki_p_admin eq 'y'}
							<a class="link tips" href="tiki-assignuser.php?assign_user={$userinfo.login|escape:"url"}" title=":{tr}Assign group{/tr}">
								{icon name='group' align="right" alt="{tr}Assign Group{/tr}"}
							</a>
						{/if}
						<a class="link tips" href="tiki-user_preferences.php?userId={$userinfo.userId}" title=":{tr}Change user preferences{/tr}">
							{icon name='wrench' align="right" alt="{tr}Change user preferences{/tr}"}
						</a>
					{/if}
				</div>
			</div>

			{if isset($user_picture_id)}
				<div class="userpicture">
					{wikiplugin _name="img" fileId="$user_picture_id"}{/wikiplugin}
				</div>
			{/if}

			<div class="panel panel-default">
				<div class="panel-body">
					{if $avatar}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Profile picture{/tr} ({tr}User Icon{/tr}):</div>
							<div class="pull-right">
								{if $userinfo.login eq $user}<a href="tiki-pick_avatar.php">{/if}
								{$avatar}
								{if $userinfo.login eq $user}</a>{/if}
							</div>
						</div>
					{/if}

					{if $realName}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Real Name:{/tr}</div>
							<div class="pull-right">{$realName|escape}</div>
						</div>
					{/if}
					{if $prefs.feature_community_gender eq 'y' and $gender neq 'Hidden' and $gender}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Gender:{/tr}</div>
							<div class="pull-right">{tr}{$gender}{/tr}</div>
						</div>
					{/if}
					{if $email_isPublic neq 'n' and $userinfo.email neq ''}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Email:{/tr}</div>
							<div class="pull-right">{mailto address=$userinfo.email text=$scrambledEmail encode="javascript"}</div>
						</div>
					{elseif $email_isPublic eq 'n' and $userinfo.email neq '' and $tiki_p_admin eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Email:{/tr}</div>
							<div class="pull-right">
								{mailto address=$userinfo.email encode="javascript"}
								<i>{tr}(non public){/tr}</i>
							</div>
						</div>
					{/if}
					{if !empty($country) and $country != 'Other'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Country:{/tr}</div>
							<div class="pull-right">{$userinfo.login|countryflag} {tr}{$country|stringfix}{/tr}</div>
						</div>
					{/if}
					{if $prefs.change_theme ne 'n'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Theme:{/tr}</div>
							<div class="pull-right">{$user_style}</div>
						</div>
					{/if}
					{if $prefs.change_language eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Language:{/tr}</div>
							<div class="pull-right">{$user_language}</div>
						</div>
					{/if}
					{if $homePage}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Homepage:{/tr}</div>
							<div class="pull-right">
								<a href="{$homePage|escape}" class="link" title="{tr}User's homepage{/tr}">
									{$homePage|escape}
								</a>
							</div>
						</div>
					{/if}
					{if $prefs.feature_score eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Score:{/tr}</div>
							<div class="pull-right">{$userinfo.score|star}{$userinfo.score}</div>
						</div>
					{/if}
					{if $prefs.feature_wiki eq 'y' && $prefs.feature_wiki_userpage eq 'y' && ($userPage_exists or $user == $userinfo.login)}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Personal Wiki Page:{/tr}</div>
							<div class="pull-right">
								{if $userPage_exists}
									<a class="link" href="tiki-index.php?page={$prefs.feature_wiki_userpage_prefix|escape:'url'}{$userinfo.login|escape:'url'}">
										{$prefs.feature_wiki_userpage_prefix}{$userinfo.login}
									</a>
								{elseif $user == $userinfo.login}
									{$prefs.feature_wiki_userpage_prefix}{$userinfo.login}
									<a class="link" href="tiki-editpage.php?page={$prefs.feature_wiki_userpage_prefix|escape:'url'}{$userinfo.login|escape:'url'}"
											title="{tr}Create Page{/tr}">?</a>
								{else}&nbsp;{/if}
							</div>
						</div>
					{/if}

					<div class="clearfix {cycle}">
						<div class="pull-left">{tr}Last login:{/tr}</div>
						<div class="pull-right">{$userinfo.lastLogin|tiki_short_datetime}</div>
					</div>

					{* Custom database fields *}
					{section name=ir loop=$customfields}

						{if $customfields[ir].show}
							<div class="clearfix {cycle}">
								<div class="pull-left">{$customfields[ir].label}:</div>
								<div class="pull-right">{$customfields[ir].value}</div>
							</div>
						{/if}
					{/section}
				</div>
			</div>

			{if $prefs.feature_friends eq 'y'}
			<h3>{tr}Friendship Network{/tr}</h3>
				{if $user eq $userinfo.login}
			<h4>{tr}Your relation to other users{/tr}</h4>
					{module module=friend_list nobox=y}
				{else}
			<h4>{tr}Relation of this user to you{/tr}</h4>
			<div id="friendship"></div>
					{jq}
						$('#friendship').load("tiki-user-info?username={{$userinfo.login}} .friendship");
					{/jq}
				{/if}
			{/if}

		{else}{* infoPublic eq 'n' *}
			<div>
				{remarksbox type="info" title="Private"}{tr}The user has chosen to make his information private{/tr}{/remarksbox}
			</div>
		{/if}
	{/tab}

	{if $prefs.user_tracker_infos and $infoPublic eq "y"}
		{tab name="{tr}Additional Information{/tr}"}<commit_msg>[FIX] forgot to include the add friend / follow button<commit_after>{* $Id$ *}
{capture assign="viewuser"}{$userwatch|escape:"url"}{/capture}
{title url="tiki-user_information.php?view_user=$viewuser"}{tr}User Information{/tr}{/title}

{if "$userwatch" eq "$user" }
	{include file='tiki-mytiki_bar.tpl'}
{/if}

{if $prefs.feature_tabs neq 'y' and $user and $prefs.feature_messages eq 'y' and $tiki_p_messages eq 'y' and $allowMsgs eq 'y'}
	<div class="t_navbar">
		{button href="#message" class="btn btn-default" _text="{tr}Send me a message{/tr}"}
	</div>
{/if}

{tabset name="user_information"}
	{tab name="{tr}Basic Data{/tr}"}
		{if $infoPublic eq 'y'}
			<h2>{$userinfo.login}</h2>
			<div class="clearfix">
				<div class="pull-right">
					{if $tiki_p_admin eq 'y' or $userinfo.login eq $user}
						{if $tiki_p_admin eq 'y'}
							<a class="link tips" href="tiki-assignuser.php?assign_user={$userinfo.login|escape:"url"}" title=":{tr}Assign group{/tr}">
								{icon name='group' align="right" alt="{tr}Assign Group{/tr}"}
							</a>
						{/if}
						<a class="link tips" href="tiki-user_preferences.php?userId={$userinfo.userId}" title=":{tr}Change user preferences{/tr}">
							{icon name='wrench' align="right" alt="{tr}Change user preferences{/tr}"}
						</a>
					{/if}
				</div>
			</div>

			{if isset($user_picture_id)}
				<div class="userpicture">
					{wikiplugin _name="img" fileId="$user_picture_id"}{/wikiplugin}
				</div>
			{/if}

			<div class="panel panel-default">
				<div class="panel-body">
					{if $avatar}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Profile picture{/tr} ({tr}User Icon{/tr}):</div>
							<div class="pull-right">
								{if $userinfo.login eq $user}<a href="tiki-pick_avatar.php">{/if}
								{$avatar}
								{if $userinfo.login eq $user}</a>{/if}
							</div>
						</div>
					{/if}

					{if $realName}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Real Name:{/tr}</div>
							<div class="pull-right">{$realName|escape}</div>
						</div>
					{/if}
					{if $prefs.feature_community_gender eq 'y' and $gender neq 'Hidden' and $gender}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Gender:{/tr}</div>
							<div class="pull-right">{tr}{$gender}{/tr}</div>
						</div>
					{/if}
					{if $email_isPublic neq 'n' and $userinfo.email neq ''}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Email:{/tr}</div>
							<div class="pull-right">{mailto address=$userinfo.email text=$scrambledEmail encode="javascript"}</div>
						</div>
					{elseif $email_isPublic eq 'n' and $userinfo.email neq '' and $tiki_p_admin eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Email:{/tr}</div>
							<div class="pull-right">
								{mailto address=$userinfo.email encode="javascript"}
								<i>{tr}(non public){/tr}</i>
							</div>
						</div>
					{/if}
					{if !empty($country) and $country != 'Other'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Country:{/tr}</div>
							<div class="pull-right">{$userinfo.login|countryflag} {tr}{$country|stringfix}{/tr}</div>
						</div>
					{/if}
					{if $prefs.change_theme ne 'n'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Theme:{/tr}</div>
							<div class="pull-right">{$user_style}</div>
						</div>
					{/if}
					{if $prefs.change_language eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Language:{/tr}</div>
							<div class="pull-right">{$user_language}</div>
						</div>
					{/if}
					{if $homePage}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Homepage:{/tr}</div>
							<div class="pull-right">
								<a href="{$homePage|escape}" class="link" title="{tr}User's homepage{/tr}">
									{$homePage|escape}
								</a>
							</div>
						</div>
					{/if}
					{if $prefs.feature_score eq 'y'}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Score:{/tr}</div>
							<div class="pull-right">{$userinfo.score|star}{$userinfo.score}</div>
						</div>
					{/if}
					{if $prefs.feature_wiki eq 'y' && $prefs.feature_wiki_userpage eq 'y' && ($userPage_exists or $user == $userinfo.login)}
						<div class="clearfix {cycle}">
							<div class="pull-left">{tr}Personal Wiki Page:{/tr}</div>
							<div class="pull-right">
								{if $userPage_exists}
									<a class="link" href="tiki-index.php?page={$prefs.feature_wiki_userpage_prefix|escape:'url'}{$userinfo.login|escape:'url'}">
										{$prefs.feature_wiki_userpage_prefix}{$userinfo.login}
									</a>
								{elseif $user == $userinfo.login}
									{$prefs.feature_wiki_userpage_prefix}{$userinfo.login}
									<a class="link" href="tiki-editpage.php?page={$prefs.feature_wiki_userpage_prefix|escape:'url'}{$userinfo.login|escape:'url'}"
											title="{tr}Create Page{/tr}">?</a>
								{else}&nbsp;{/if}
							</div>
						</div>
					{/if}

					<div class="clearfix {cycle}">
						<div class="pull-left">{tr}Last login:{/tr}</div>
						<div class="pull-right">{$userinfo.lastLogin|tiki_short_datetime}</div>
					</div>

					{* Custom database fields *}
					{section name=ir loop=$customfields}

						{if $customfields[ir].show}
							<div class="clearfix {cycle}">
								<div class="pull-left">{$customfields[ir].label}:</div>
								<div class="pull-right">{$customfields[ir].value}</div>
							</div>
						{/if}
					{/section}
				</div>
			</div>

			{if $prefs.feature_friends eq 'y'}
			<h3>{tr}Friendship Network{/tr}</h3>
				{if $user eq $userinfo.login}
			<h4>{tr}Your relation to other users{/tr}</h4>
					{module module=friend_list nobox=y}
				{else}
			<h4>{tr}Relation of this user to you{/tr}</h4>
			<div id="friendship"></div>
			<div id="addfriend"></div>
					{jq}
						$('#friendship').load("tiki-user-info?username={{$userinfo.login}} .friendship");
						$('#addfriend').load("tiki-user-info?username={{$userinfo.login}} .add-friend");
					{/jq}
				{/if}
			{/if}

		{else}{* infoPublic eq 'n' *}
			<div>
				{remarksbox type="info" title="Private"}{tr}The user has chosen to make his information private{/tr}{/remarksbox}
			</div>
		{/if}
	{/tab}

	{if $prefs.user_tracker_infos and $infoPublic eq "y"}
		{tab name="{tr}Additional Information{/tr}"}
{'fraction_non_alphanumeric': 0.20727243793761935, 'fraction_numerical': 0.001273074474856779, 'mean_word_length': 3.2079009039169737, 'pattern_counts': {'":': 4, '<': 237, '<?xml version=': 0, '>': 237, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2538454', 'n_tokens_mistral': 5996, 'n_tokens_neox': 4589, 'n_words': 845}