{if $ajax ne '1'}
{if $form.page eq '4'}
<div class="pr_text">
	<div class="albums_wrapper">
		<div class="albums_menu">
			<a href="#" onclick="javascript: ShowTab(8,'{$menu.4}', 1, 2); return false;" class="photo-icon" title="{$lang.section.photos}">&nbsp;</a>
			<a href="#" onclick="javascript: ShowTab(9,'{$menu.4}', 1, 2); return false;" class="audio-icon" title="{$lang.section.audio}">&nbsp;</a>
			<a href="#" onclick="javascript: ShowTab(10,'{$menu.4}', 1, 2); return false;" class="video-icon" title="{$lang.section.video}">&nbsp;</a>
		</div>
		<div class="albums_content">
			<!-- begin upload section -->
			{if $data_9.id_album ne 0}
			{if $data_9.photo || $data_9.audio || $data_9.video}
				<h3 class="p-b5">
					{if $album_page.arr_name eq 'photo'}
						{$lang.section.photos}
					{elseif $album_page.arr_name eq 'audio'}
						{$lang.section.audio}
					{elseif $album_page.arr_name eq 'video'}
						{$lang.section.video}
					{/if}
					
					{if $group_adult_allow}
						<span class="adult_content_check_span float_right">
							<label for="adult_content_check">{$lang.adult_content_check}</label>&nbsp;&nbsp;
							<input id="adult_content_check" type="checkbox" {if $user_adult_allow}checked{/if} onclick="changeAdultAllow(this, {literal}function(){ShowTab({/literal}{$data_9.form_sub_page},'{$form.action}&sel=4&id_album={$data_9.id_album}', 4);{literal}}{/literal})" />
						</span>
					{/if}
				</h3>
			{/if}
			<div>
				{if $items_links_top}
					<div style="padding: 15px 0;display:table;width:100%;">
						<div class="float_right">
						<div class="b-page-n">
						{foreach item=item from=$items_links_top name=links}
							{if $smarty.foreach.links.first}
								{$lang.general.showing}&nbsp;{$current_page}&nbsp;{$lang.general.of}&nbsp;{$num_page}&nbsp;
							{/if}
							{if $item.previous_page eq 1}
								<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="back-page-act" id="back-page-act_top" alt="{$lang.general.prev}" title="{$lang.general.prev}">&nbsp;</a>
							{elseif $item.previous_page eq 2}
								<a href="javascript: void(0);" class="back">&nbsp;</a>
							{/if}
							{if $item.next_page eq 1}
								<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="next-page-act" id="next-page-act_top" alt="{$lang.general.next}" title="{$lang.general.next}">&nbsp;</a>
							{elseif $item.next_page eq 2}
								<a href="javascript: void(0);" class="next">&nbsp;</a>
							{/if}
						{/foreach}
						</div>
						</div>
					</div>
				{/if}
				
				{if $data_9.photo}
					{foreach key=key item=item from=$data_9.photo}
						<div class="mma_item">
							<a class="imgcanvas_container" {if $guest ne 1}href="#" onclick="launchWindow('{$item.view_link.file}','{$item.view_link.str}',800,550); return false;"{/if}>
								<img src="{$item.thumb_file}" class="icon imgcanvas" alt="" {$item.sizes}/>
							</a><br/>
							<p>{$lang.gallary.rating}:&nbsp;{$item.gallery_rate}&nbsp;{$lang.gallary.points}</p>
							<p>{$lang.gallary.views}:&nbsp;{$item.views}</p>
						</div>
					{/foreach}
				{elseif $data_9.audio}
					<table cellpadding="0" cellspacing="0" border="0" width="100%">
					{foreach key=key item=item from=$data_9.audio}
						<div class="audio_item">
							<span>
							{if $guest ne 1}
								<a class="play_audio_btn" href="javascript:void(0);" onclick="playAudio('{$item.file_path}', '{$item.song_author|escape:javascript} - {$item.song_name|escape:javascript}', this)">
							{/if}<img src="{$site_root}{$template_root}{$template_images_root}/albums_listen_audio.gif" alt=""/>{if $guest ne 1}</a>{/if}
							</span>
							<span class="song_author">{$item.song_author}</span> - {$item.song_name}&nbsp;&nbsp;&nbsp;
							<b>{$item.song_length}</b>
						</div>
					{/foreach}
					</table>
					<div class="clear"></div>
				{elseif $data_9.video}	
						<div style="padding-top: 10px;">
							{foreach key=key item=item from=$data_9.video}
								<div class="float_left" style="margin:8px;">
									<div style="margin-bottom: 4px; width: 140px; height: 140px;">
										<a class="imgcanvas_container" {if $item.view_link.str && $guest ne 1}href="#" onclick="launchWindow('{$item.view_link.file}','{$item.view_link.str}',600,300); return false;"{/if}>
											{if $item.thumb_file != "default"}
												<img src="{$item.thumb_file}" border=0 {$item.sizes} class="icon {if $item.is_adult eq 1}imgcanvas{/if}" alt="">
											{else}
												<div class="one_video_icon"></div>
											{/if}
										</a>
									</div>
									<div class="float_left text-overflow" style="width: 140px;">{if $item.upload_title}{$item.upload_title}{else}{$lang.profile.untitled}{/if}</div>
									<div style="padding-top: 3px;">{$lang.gallary.rating}:&nbsp;{$item.gallery_rate}&nbsp;{$lang.gallary.points}</div>
									<div style="padding-top: 3px;">{$lang.gallary.views}:&nbsp;
										<span id="v{$smarty.foreach.a.iteration}">{$item.views}</span>
									</div>
									{if $item.user_comment}<div class="text">{$item.user_comment}</div>{/if}
								</div>
							{/foreach}
						</div>
                        {*foreach key=key item=item from=$data_9.video name=foo}
						<div class="mma_item" id="item_{$smarty.foreach.foo.iteration}">
							<a class="imgcanvas_container" href="#" onclick="launchWindow('{$site_root}/{$seo.myprofile}','sel=start_video&id_item={$data_9.id_album}&type={$album_page.upload_type}&id_subitem={$item.id}',600,400); return false;">
							{if !$item.status}
                                <div style="z-index:8888; position: absolute; float: left;"><img src="{$site_root}{$template_root}{$template_images_root}/icon_waiting.png" alt="{$lang.alt.approve}" title="{$lang.alt.approve}" /></div>
                            {/if}
                            	{if $item.thumb_file eq 'default'} 
									<div class="one_video_icon"></div>
								{else}
									<img src="{$item.thumb_file}" alt="" {$item.sizes} class="video_item imgcanvas"/>
								{/if}
							</a>
							<div class="mma_item_buttons" style="line-height:1;">
								<a href="#" onclick="launchWindow('{$site_root}/{$seo.myprofile}','sel=start_video&id_item={$data_9.id_album}&type={$album_page.upload_type}&id_subitem={$item.id}',600,300); return false;" class="small-view-icon float_left">&nbsp;</a>
								<a href="#" onclick="launchWindow('{$site_root}/{$seo.myprofile}','sel=edit_item_form&id_item={$data_9.id_album}&type={$album_page.upload_type}&id_subitem={$item.id}',400,300); return false;" class="small-edit-icon float_left">&nbsp;</a>
								<!--a onclick="javascript: if (window.confirm('{$lang.confirm.delete_video|escape:javascript}')) location.href='{$item.del_link}'; else return false;" class="small-del-icon float_left">&nbsp;</a-->
								<a onclick="javascript: if (window.confirm('{$lang.confirm.delete_video|escape:javascript}'))  DeleteUpload('{$item.del_link}', 'item_{$smarty.foreach.foo.iteration}'); else return false;" class="small-del-icon float_left">&nbsp;</a>
								<div class="clear"></div>
							</div>
						</div>
						{/foreach*}
						<div class="clear"></div>
				{/if}
				
				{if $items_links_bottom}
					<div style="padding: 15px 0;display:table;width:100%;">
						<div class="search_link">
							<div class="sorting-long">
								<div class="b-page-n">	
									{foreach item=item from=$items_links_bottom}
										{if $item.first_page eq 1}
											<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="first-page-act" title="{$lang.general.first}">&nbsp;</a>
										{elseif $item.first_page eq 2}
											<a href="javascript: void(0);" class="first-page">&nbsp;</a>
										{/if}
										
										{if $item.previous_page eq 1}
											<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="back-page-act" id="back-page-act_bottom" alt="{$lang.general.prev}" title="{$lang.general.prev}">&nbsp;</a>
										{elseif $item.previous_page eq 2}
											<a href="javascript: void(0);" class="back">&nbsp;</a>
										{/if}
										
										{if $item.selected}
											<a href="javascript: void(0);" class="act-page">{$item.name}</a>
										{else}
											<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;">{$item.name}</a>
										{/if}
										
										{if $item.delimiter}
											{$item.delimiter}
										{/if}
										
										{if $item.next_page eq 1}
											<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="next-page-act" id="next-page-act_bottom" alt="{$lang.general.next}" title="{$lang.general.next}">&nbsp;</a>
										{elseif $item.next_page eq 2}
											<a href="javascript: void(0);" class="next">&nbsp;</a>
										{/if}
											
										{if $item.last_page eq 1}
											<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="last-page-act" title="{$lang.general.last}">&nbsp;</a>
										{elseif $item.last_page eq 2}
											<a href="javascript: void(0);" class="last-page">&nbsp;</a>
										{/if}	
									{/foreach}
								</div>
							</div>
						</div>
					</div>
				{/if}
			{/if}
		</div>
	{if $_album && $data_9.id_album == 0}
		<div class="albums">
			<h3 class="p-b5">{$lang.section.albums}
				{if $group_adult_allow}
					<span class="adult_content_check_span float_right">
						<label for="adult_content_check">{$lang.adult_content_check}</label>&nbsp;&nbsp;
						<input id="adult_content_check" type="checkbox" {if $user_adult_allow}checked{/if} onclick="changeAdultAllow(this, {literal}function(){ShowTab({/literal}{$data_9.form_sub_page},'{$form.action}&sel=4&id_album={$data_9.id_album}', 4);{literal}}{/literal})" />
					</span>
				{/if}
			</h3>
            {if $album_links_top}
				<div style="padding: 15px 0; display:table; width:100%;">
					<div style="float:right;">
					<div class="b-page-n">
					{foreach item=item from=$album_links_top name=links}
						{if $smarty.foreach.links.first}
							{$lang.general.showing}&nbsp;{$current_page}&nbsp;{$lang.general.of}&nbsp;{$num_page}&nbsp;
						{/if}
						{if $item.previous_page eq 1}
							<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="back-page-act" id="back-page-act_top" alt="{$lang.general.prev}" title="{$lang.general.prev}">&nbsp;</a>
						{elseif $item.previous_page eq 2}
							<a href="javascript: void(0);" class="back">&nbsp;</a>
						{/if}
						{if $item.next_page eq 1}
							<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="next-page-act" id="next-page-act_top" alt="{$lang.general.next}" title="{$lang.general.next}">&nbsp;</a>
						{elseif $item.next_page eq 2}
							<a href="javascript: void(0);" class="next">&nbsp;</a>
						{/if}
					{/foreach}
					</div>
					</div>
				</div>
			{/if}		
			{foreach item=item from=$_album name=k}
				<div class="albums_item">
					<div class="album_icon {if $album_page.upload_type eq 'f'}photo{elseif $album_page.upload_type eq 'a'}audio{elseif $album_page.upload_type eq 'v'}video{/if}" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}&id_album={$item.id}', 4); return false;">
						{if $item.first_photo}
							<img height="130px" width="130px" src="{$item.first_photo}" />
						{/if}
					</div>
					<div class="alb_descr">					
						<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}&id_album={$item.id}', 4); return false;">{$item.title}</a><br/>
						{$lang.users.created}:&nbsp;{$item.creation_date}<br/>
						{if $album_page.upload_type eq 'f'}{$lang.users.photos_count}{elseif $album_page.upload_type eq 'a'}{$lang.users.audio_count}{elseif $album_page.upload_type eq 'v'}{$lang.users.video_count}{/if}:&nbsp;{$item.items_count}<br/>
						<div class="mma_item_buttons mma_item_buttons_gr mma_item_buttons_gr1">
							<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}&id_album={$item.id}', 4); return false;" class="mma_item_buttons_itm1"></a>
							<a href="#" onclick="launchWindow('{$site_root}/{$seo.myprofile}','sel=edit_album_form&type={$album_page.upload_type}&id_item={$item.id}',500,275); return false;" class="mma_item_buttons_itm2"></a>
							<a href="{$site_root}/{$seo.myprofile}?sel=del_album&id_album={$item.id}&sub={$data_9.form_sub_page}" class="mma_item_buttons_itm3"></a>
							<div class="clear"></div>
						</div>
						
					</div>
				</div>
		    {/foreach}
		    <div class="clear"></div>
		    {if $links_page}
				<div class="links_div">
					{foreach item=item from=$links_page}
						<div class="page_div{if $item.selected eq '1'}_active{/if}">
							<div style="margin: 5px"><a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="page_link{if $item.selected eq '1'}_active{/if}">{$item.name}</a></div>
						</div>
					{/foreach}
					<div class="clear"></div>
				</div>
			{/if}
		</div>
        {if $album_links_bottom}
				<div style="padding: 15px 0;display:table;width:100%;">
					<div class="search_link">
						<div class="sorting-long">
							<div class="b-page-n">	
								{foreach item=item from=$album_links_bottom}
									{if $item.first_page eq 1}
										<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="first-page-act" title="{$lang.general.first}">&nbsp;</a>
									{elseif $item.first_page eq 2}
										<a href="javascript: void(0);" class="first-page">&nbsp;</a>
									{/if}
									
									{if $item.previous_page eq 1}
										<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="back-page-act" id="back-page-act_bottom" alt="{$lang.general.prev}" title="{$lang.general.prev}">&nbsp;</a>
									{elseif $item.previous_page eq 2}
										<a href="javascript: void(0);" class="back">&nbsp;</a>
									{/if}
									
									{if $item.selected}
										<a href="javascript: void(0);" class="act-page">{$item.name}</a>
									{else}
										<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;">{$item.name}</a>
									{/if}
									
									{if $item.delimiter}
										{$item.delimiter}
									{/if}
									
									{if $item.next_page eq 1}
										<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="next-page-act" id="next-page-act_bottom" alt="{$lang.general.next}" title="{$lang.general.next}">&nbsp;</a>
									{elseif $item.next_page eq 2}
										<a href="javascript: void(0);" class="next">&nbsp;</a>
									{/if}
										
									{if $item.last_page eq 1}
										<a href="#" onclick="javascript: ShowTab({$data_9.form_sub_page},'{$menu.4}{$item.link}', {$data_9.form_act}); return false;" class="last-page-act" title="{$lang.general.last}">&nbsp;</a>
									{elseif $item.last_page eq 2}
										<a href="javascript: void(0);" class="last-page">&nbsp;</a>
									{/if}	
								{/foreach}
							</div>
						</div>
					</div>
				</div>
			{/if}	
	{/if}
	<div class="clear"></div>
</div>
{/if}
{/if}

{if $form.page eq '5'}
	{strip}
	{if $ajax ne '1'}
		<!-- begin rating -->
		<div class="rating_cont">
			<div class="rating {if ($data_10.allow_rate) && ($form.guest_user != 1)}view_rating{else}my_rating{/if}">
				<div class="rating_left" style="height: 20px;">
					{if ($data_10.allow_rate) && ($form.guest_user != 1)}
						<form id="voting" name="voting" method="post" action="{$form.action}">
							<div class="float_left" style="padding-top: 2px; float: left;">
								<input type="hidden" name="sel" value="vote">
								<span class="float_left" style="float: left;">{$lang.rating.not}</span>
								<select id="rate_user" name="r" onload="rate();">
									<option value="1">1</option>
									<option value="2">2</option>
									<option value="3">3</option>
									<option value="4">4</option>
									<option value="5">5</option>
									<option value="6">6</option>
									<option value="7">7</option>
									<option value="8">8</option>
									<option value="9">9</option>
									<option value="10">10</option>
								</select>
								{literal}
								<script type="text/javascript">
									function rate(){
										$('#rate_user').selectToUISlider( {
											labels: 10
										});
									}
									rate();
								</script>
								{/literal}
								<span class="float_left" style="float: left;">{$lang.rating.hot}</span>
							</div>						
							<div class="float_left" style="height: 25px; padding-top: 2px; float: left;">
								<ins class="small-active-icon" style="margin-top: 4px; float: none;" onClick="javascript:document.voting.submit();">&nbsp;</ins>
							</div>
						</form>
					{else}
					<div class="rating_bar">
						<span class="float_left">{$lang.rating.not}</span>
						{$data_10.current_rating_bar}
						<span class="float_left">{$lang.rating.hot}</span>
					</div>
					{/if}
				</div>
				<div class="rating_right">
					<span class="">{$lang.subsection.rating}:&nbsp;{$data_10.current_rating}</span>
					&nbsp;&nbsp;|&nbsp;&nbsp;
					<span class="">{$lang.profile.votes}:&nbsp;{$data_10.all_vote}</span>
					&nbsp;&nbsp;|&nbsp;&nbsp;
					<span class="text_red"><a href="{$site_root}/{$seo.top_users}">{$lang.profile.place}:&nbsp;{if $data_10.place}{$data_10.place}{else}{*$lang.general.not_top_rating*}-{/if}</a></span>
					&nbsp;&nbsp;|&nbsp;&nbsp;
					<span class="text_red"><a href="{$site_root}/{$seo.hot_or_not}">{$lang.rating.rate_other}</a></span>
				</div>
			</div>
		</div>
		<!-- end rating -->
		
		<h3 class="p-b5" style="margin-bottom:0;">{$lang.wall_events.header}
			{if $group_adult_allow}
				<span class="adult_content_check_span float_right">
					<label for="adult_content_check">{$lang.adult_content_check}</label>&nbsp;&nbsp;
					<input id="adult_content_check" type="checkbox" {if $user_adult_allow}checked{/if} onclick="changeAdultAllow(this, {literal}function(resp){if(resp.status == 1 && window.wall_events){window.wall_events.reload();}}{/literal})" />
				</span>
			{/if}
		</h3>
		<div id="wall_events" class="wall_events">
			{include file="$gentemplates/wall_events.tpl"}
		</div>
		{literal}
		<script>
			window.wall_events = new WallEvents().init({
				type: 'user_wall',
				id_user: parseInt('{/literal}{$id}{literal}'),
				all_loaded: parseInt('{/literal}{$events.all_loaded}{literal}'),
				min_id: {/literal}{if $events.min_id}{$events.min_id}{else}0{/if}{literal},
				max_id: {/literal}{if $events.max_id}{$events.max_id}{else}0{/if}{literal},
				id: 'wall_events',
				is_guest: user_id == 2 ? 1 : 0,
				url: '{/literal}{$server}/ajax_backend.php{literal}',
				view_button_title: '{/literal}{$lang.button.view_more|escape:javascript}{literal}',
				send_button_title: '{/literal}{$lang.button.send|escape:javascript}{literal}',
				placeholder: '{/literal}{$lang.wall_events.placeholder_user|escape:javascript}{literal}',
				onInit: function(){$('#wall_events_wrapper').find('input, textarea').placeholder();}
			});
		</script>
		{/literal}
	
		<!-- comments begin -->    
	{/if}
{*			{if $ajax ne '1'}
				<h3 class="p-b5">{$lang.subsection.comments}</h3>
			{/if}
						
			{if $links_top}
				{if $data_10.comments}{include file="$gentemplates/pagination_top.tpl"}{/if}
			{/if}
			<div id="comments_area">
				{if $data_10.comments}{include file="$site_path/$template_root/viewprofile_comment.tpl"}{/if}
			</div>
			
			{if $links_bottom}
				{if $data_10.comments}{include file="$gentemplates/pagination_bottom.tpl"}{/if}
			{/if}
				
			{if $ajax ne '1'}					
			{if $guest ne 1}
			{$lang.profile.add_comment}
			<form name="comment_form" method="post" action="{$form.action}" style="margin: 0px;">
				<input type="hidden" name="sel" value="comment">
				<input type="hidden" id="id" value="{$id}">
				<div class="content_alloc classfields">						
				<div>
					<textarea style="resize: none;" name="message" id="message" onkeyup="BadWords('message'); textchange_2()" cols=90 rows=4></textarea>
					<div id="bad_div_message" class="bad_div"></div>
					<div style="margin: 10px 2px; text-align: {$default_right}; display: table; width: 100%;">
					<div class="float_right" style="margin-top:9px;margin-{$default_right}:7px;" id="count_sym2">256</div>
					<script>{literal}
						function textchange_2() {
							var count = 256;
							$('#count_sym2').text(count);
							a = $('#message').val().length;
							if (a > count) {
								$('#message').val($('#message').val().substring(0, count));
							}
							a = $('#message').val().length;
							$('#count_sym2').text(count - a);
							if (a > count){
								$('#message').css("disabled", "disabled");
							}
						}
					{/literal}</script>
				
					<div style="height: 16px; width: 10px;" class="icon_smail_for_comment float_left" onclick="return displaySmileLayer();"></div>
					<div id=smiles class="smiles" style="display:none; {$default_left}: 264px; width: 255px;">                                   
						<ul>
						{section name=sm loop=$smiles}
						{if $use_default_smiles eq '1'}
						<li><a style="cursor:pointer;" onclick="document.getElementById('message').value=document.getElementById('message').value+'{$smiles[sm].value}'; document.getElementById('smiles').style.display = 'none';"><img src="{$site_root}{$template_root}/emoticons/{$smiles[sm].file}" class="smile_icon" alt=""></a></li>
						{else}
						<li><a style="cursor:pointer;" onclick="document.getElementById('message').value=document.getElementById('message').value+'{$smiles[sm].value}'; document.getElementById('smiles').style.display = 'none';"><img src="{$site_root}/uploades/smiles/{$smiles[sm].file}" class="smile_icon" alt=""></a></li>
						{/if}
						{/section}
						</ul>
					</div>
					</div>
				</div>
				</div>                        
				<input type="button" onclick="SubmitComment(this);" value="{$lang.button.add}">
			</form>
			{/if}
		</div>
	</div>
	<!-- comments begin -->
			
		{if $use_tags}
		<!-- begin tags -->
		{if $guest ne 1}
		    <div class="pr_file_cont">
			<h3 class="p-b5">{$lang.section.tags}</h3>
				{if $data_10.user_tags}
					<div id="user_tags">
						<p>
							{section name=s loop=$data_10.user_tags}
							<a href="{$data_10.user_tags[s].searchlink}" style="font-size: {$data_10.user_tags[s].size}px; vertical-align: baseline;" title="{$data_10.user_tags[s].count}">{$data_10.user_tags[s].tag}</a>&nbsp;&nbsp;
							{/section}
						</p>
					</div>
				{/if}
				{if $data_10.my_tags}
					<!-- begin my tags list -->
					<div id="my_tags">
						<p>{$lang.subsection.i_tag_profile}</p>
						<p>
							{section name=s loop=$data_10.my_tags}
							{$data_10.my_tags[s].tag}&nbsp;<a href="{$data_10.my_tags[s].dellink}"><b>x</b></a>&nbsp;&nbsp;
							{/section}
						</p>
					</div>
					<div class="rating_separ"></div>
					<!-- end my tags list -->
				{/if}
				<!-- begin add tag -->
				<div id="add_tags">
					<form name="add_tag" method="post" action="{$form.action}" style="margin:0px">
						<input type="hidden" name="sel" value="addtag">
						<p><input type="text" name="tag"></p>
						<p><input type="submit" value="{$lang.tag_me}"></p>
					</form>
				</div>
				<!-- end add tag -->
		    </div>
		    {/if}
			<!-- begin tags -->			
		{/if}
		{/if}		
				*}
	{/strip}
{/if}
{if $ajax ne '1'}	
{literal}
<script language="JavaScript" type="text/javascript">


  function Iteration(par){
	i= $('#'+par).text();
	i++;
	$('#'+par).text(i);
  }
  
function displaySmileLayer(id)
{
	if (!id){id = 'smiles'}
	if (document.getElementById(id).style.display == 'none') {
		document.getElementById(id).style.display = 'inline-block';
	} else {
		document.getElementById(id).style.display = 'none';
	}
	return false;
}


var delete_progress = 0;
var submit_html;
function SubmitComment(obj){
	if($('#message').val() == '' || $('#message').val() == undefined){
		return;
	}
	submit_html = $('#submit_comment').html();
	$('#submit_comment').html('<img border=0 src="{/literal}{$site_root}{$template_root}{$template_images_root}/ajax_loader.gif{literal}">');


	$.ajax({
		type: 'POST',
		url: SEO_SITE_ROOT + '/viewprofile.php',
		data: {'sel': 'add_owner_comment', 'message': $('#message').val(), 'id':$('#id').val()},
		success: function(msg){
			if(msg != "error"){
                            if (msg == "black"){
                                var error_message = '{/literal}{$lang.err.email_black_list_err|replace:"'":"\\'"}{literal}';
                                ShowAjaxError('', error_message);
                            }else{
                                //alert(msg);
                                $('#comments_area').prepend(msg);
                                $('#message').val('');
                                $('#submit_comment').html(submit_html);
                                /*var error_message = '{/literal}{$lang.err.info_finding_1|replace:"'":"\\'"}{literal}';
                                alert(error_message);*/
                            }
			}
			else{
                            $('#submit_comment').html(submit_html);
                            $('#message').val('');
                            $('#comments_area').prepend(msg);
			}
		}
	});
}

function DeleteOwnerComment(obj, comment_id){
	var delete_alert = '{/literal}{$lang.err.comment_delete_confirm|escape:javascript}{literal}';
	if(delete_alert != ''){
		if(!confirm(delete_alert)){
			return;
		}
	}

	if(delete_progress == 0){
		delete_progress = 1;
	}else{
		return;
	}
	if(comment_id == undefined || comment_id == 0 || obj == undefined){
		return;
	}
	
	$(obj).html('<img border=0 src="{/literal}{$site_root}{$template_root}{$template_images_root}/ajax_loader.gif{literal}">');
	$(obj).blur();
	$.ajax({
		type: 'POST',
		url: SEO_SITE_ROOT + '/viewprofile.php',
		data: {'sel':'delete_owner_comment', 'comment_id':comment_id},
		success: function(msg){
			if(msg != 'ERROR'){
				delete_progress = 0;
				$(obj).closest('.comment_wrapper').remove();
			}
			else{
				delete_progress = 0;
				var del_comment = '{/literal}{$lang.err.comment_cant_del|escape:javascript}{literal}';

				$(obj).html('[{/literal}{$lang.button.delete|escape:html}{literal}]');
				if(del_comment != ''){
					alert(del_comment);
				}
			}
		}
	});
}
function ShowUploadForm(par) {
	if (par == 'f') {
		if (document.getElementById('upload_photo_form').style.display == 'none') {
			document.getElementById('upload_photo_form').style.display = 'inline';
		} else {
			document.getElementById('upload_photo_form').style.display = 'none';
		}
	} else if (par == 'a') {
		if (document.getElementById('upload_audio_form').style.display == 'none') {
			document.getElementById('upload_audio_form').style.display = 'inline';
		} else {
			document.getElementById('upload_audio_form').style.display = 'none';
		}
	} else if (par == 'v') {
		if (document.getElementById('upload_video_form').style.display == 'none') {
			document.getElementById('upload_video_form').style.display = 'inline';
		} else {
			document.getElementById('upload_video_form').style.display = 'none';
		}
	}
	document.getElementById('focus_field').focus();
	return;
}
function ShowHideCategories(param, id_value) {
	if (document.getElementById('categories_div'+param+id_value).style.display == 'none') {
		document.getElementById('categories_div'+param+id_value).style.display = 'inline';
	} else {
		document.getElementById('categories_div'+param+id_value).style.display = 'none';
	}
	return;
}
function DeleteUploadComment(obj, comment_id){
	var delete_alert = '{/literal}{$lang.err.comment_delete_confirm|escape:javascript}{literal}';
	if(delete_alert != ''){
		if(!confirm(delete_alert)){
			return;
		}
	}

	if(delete_progress == 0){
		delete_progress = 1;
	}else{
		return;
	}
	if(comment_id == undefined || comment_id == 0 || obj == undefined){
		return;
	}
	
	$(obj).html('<img border=0 src="{/literal}{$site_root}{$template_root}{$template_images_root}/ajax_loader.gif{literal}">');
	$(obj).blur();
	$.ajax({
		type: 'POST',
		url: SEO_SITE_ROOT + '/myprofile.php',
		data: {'sel':'delete_upload_comment', 'comment_id':comment_id},
		success: function(msg){
			if(msg != 'ERROR'){
				delete_progress = 0;
				$(obj).closest('.comment_upload').remove();
			}
			else{
				delete_progress = 0;
				var del_comment = '{/literal}{$lang.err.comment_cant_del|escape:javascript}{literal}';

				$(obj).html('[{/literal}{$lang.button.delete|escape:html}{literal}]');
				if(del_comment != ''){
					alert(del_comment);
				}
			}
		}
	});
}

</script>
{/literal}
{/if}