1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-07-02 22:45:02 +03:00

Фикс багов, добавлены микроданные (micrdata) в профиль пользователя

This commit is contained in:
Denis Shakhov 2012-05-30 11:20:19 +07:00
parent f44d444e9b
commit 4655eef68c
9 changed files with 40 additions and 27 deletions

View file

@ -1,7 +1,7 @@
<div class="profile">
{hook run='profile_top_begin' oUserProfile=$oUserProfile}
<a href="{$oUserProfile->getUserWebPath()}"><img src="{$oUserProfile->getProfileAvatarPath(48)}" alt="avatar" class="avatar" /></a>
<a href="{$oUserProfile->getUserWebPath()}"><img src="{$oUserProfile->getProfileAvatarPath(48)}" alt="avatar" class="avatar" itemprop="photo" /></a>
<div id="vote_area_user_{$oUserProfile->getId()}" class="vote {if $oUserProfile->getRating()>=0}vote-count-positive{else}vote-count-negative{/if} {if $oVote} voted {if $oVote->getDirection()>0}voted-up{elseif $oVote->getDirection()<0}voted-down{/if}{/if}">
<div class="vote-label">{$aLang.user_rating}</div>
@ -15,10 +15,10 @@
<div class="count" id="user_skill_{$oUserProfile->getId()}">{$oUserProfile->getSkill()}</div>
</div>
<h2 class="page-header user-login word-wrap {if !$oUserProfile->getProfileName()}no-user-name{/if}">{$oUserProfile->getLogin()}</h2>
<h2 class="page-header user-login word-wrap {if !$oUserProfile->getProfileName()}no-user-name{/if}" itemprop="nickname">{$oUserProfile->getLogin()}</h2>
{if $oUserProfile->getProfileName()}
<p class="user-name">{$oUserProfile->getProfileName()|escape:'html'}</p>
<p class="user-name" itemprop="name">{$oUserProfile->getProfileName()|escape:'html'}</p>
{/if}
{hook run='profile_top_end' oUserProfile=$oUserProfile}

View file

@ -1,4 +1,5 @@
{assign var="sidebarPosition" value='left'}
{assign var="sMenuItemSelect" value='profile'}
{include file='header.tpl'}
{assign var="oSession" value=$oUserProfile->getSession()}
@ -50,13 +51,13 @@
{if $oGeoTarget}
<tr>
<td class="cell-label">{$aLang.profile_place}:</td>
<td>
<td itemprop="address" itemscope itemtype="http://data-vocabulary.org/Address">
{if $oGeoTarget->getCountryId()}
<a href="{router page='people'}country/{$oGeoTarget->getCountryId()}/">{$oUserProfile->getProfileCountry()|escape:'html'}</a>{if $oGeoTarget->getCityId()},{/if}
<a href="{router page='people'}country/{$oGeoTarget->getCountryId()}/" itemprop="country-name">{$oUserProfile->getProfileCountry()|escape:'html'}</a>{if $oGeoTarget->getCityId()},{/if}
{/if}
{if $oGeoTarget->getCityId()}
<a href="{router page='people'}city/{$oGeoTarget->getCityId()}/">{$oUserProfile->getProfileCity()|escape:'html'}</a>
<a href="{router page='people'}city/{$oGeoTarget->getCityId()}/" itemprop="locality">{$oUserProfile->getProfileCity()|escape:'html'}</a>
{/if}
</td>
</tr>

View file

@ -108,7 +108,11 @@
{include file='sidebar.tpl'}
{/if}
<div id="content" role="main" {if $noSidebar}class="content-full-width"{/if} {if $sidebarPosition == 'left'}class="content-right"{/if}>
<div id="content" role="main"
class="{if $noSidebar}content-full-width{/if}
{if $sidebarPosition == 'left'}content-right{/if}"
{if $sMenuItemSelect=='profile'}itemscope itemtype="http://data-vocabulary.org/Person"{/if}>
{include file='nav_content.tpl'}
{include file='system_message.tpl'}

View file

@ -1,6 +1,8 @@
jQuery(document).ready(function($){
// Хук начала инициализации javascript-составляющих шаблона
ls.hook.run('ls_template_init_start',[],window);
$('body').removeClass('no-js');
// Всплывающие окна
$('#window_login_form').jqm();

View file

@ -44,10 +44,10 @@
<a href="{router page='talk'}add/?talk_users={$oUserProfile->getLogin()}"><button class="button button-action button-action-send-message"><i class="icon-synio-send-message"></i><span>{$aLang.user_write_prvmsg}</span></button></a>
{/if}
<h2 class="page-header user-login word-wrap {if !$oUserProfile->getProfileName()}no-user-name{/if}">{$oUserProfile->getLogin()}</h2>
<h2 class="page-header user-login word-wrap {if !$oUserProfile->getProfileName()}no-user-name{/if}" itemprop="nickname">{$oUserProfile->getLogin()}</h2>
{if $oUserProfile->getProfileName()}
<p class="user-name">{$oUserProfile->getProfileName()|escape:'html'}</p>
<p class="user-name" itemprop="name">{$oUserProfile->getProfileName()|escape:'html'}</p>
{/if}
{hook run='profile_top_end' oUserProfile=$oUserProfile}

View file

@ -1,4 +1,5 @@
{assign var="sidebarPosition" value='left'}
{assign var="sMenuItemSelect" value='profile'}
{include file='header.tpl' menu='people'}
{assign var="oSession" value=$oUserProfile->getSession()}
@ -12,20 +13,20 @@
<div class="profile-info-about">
<a href="{$oUserProfile->getUserWebPath()}" class="avatar"><img src="{$oUserProfile->getProfileAvatarPath(100)}" alt="avatar" /></a>
<h3>{$aLang.profile_about}</h3>
{if $oUserProfile->getProfileAbout()}
{$oUserProfile->getProfileAbout()}
{else}
<p>Пока ничего не известно...</p>
{if $oUserCurrent and $oUserCurrent->getId() == $oUserProfile->getId()}
<a href="{router page='settings'}" class="edit">Редактировать</a>
{/if}
{/if}
</div>
<div class="profile-info-about">
<a href="{$oUserProfile->getUserWebPath()}" class="avatar"><img src="{$oUserProfile->getProfileAvatarPath(100)}" alt="avatar" itemprop="photo" /></a>
<h3>{$aLang.profile_about}</h3>
{if $oUserProfile->getProfileAbout()}
<p>{$oUserProfile->getProfileAbout()}</p>
{else}
<p>{$aLang.profile_about_empty}</p>
{/if}
<br />
{if $oUserCurrent and $oUserCurrent->getId() == $oUserProfile->getId()}
<a href="{router page='settings'}" class="edit">{$aLang.profile_about_edit}</a>
{/if}
</div>
@ -63,13 +64,13 @@
{if $oGeoTarget}
<li>
<span>{$aLang.profile_place}:</span>
<strong>
<strong itemscope itemtype="http://data-vocabulary.org/Address">
{if $oGeoTarget->getCountryId()}
<a href="{router page='people'}country/{$oGeoTarget->getCountryId()}/">{$oUserProfile->getProfileCountry()|escape:'html'}</a>{if $oGeoTarget->getCityId()},{/if}
<a href="{router page='people'}country/{$oGeoTarget->getCountryId()}/" itemprop="country-name">{$oUserProfile->getProfileCountry()|escape:'html'}</a>{if $oGeoTarget->getCityId()},{/if}
{/if}
{if $oGeoTarget->getCityId()}
<a href="{router page='people'}city/{$oGeoTarget->getCityId()}/">{$oUserProfile->getProfileCity()|escape:'html'}</a>
<a href="{router page='people'}city/{$oGeoTarget->getCityId()}/" itemprop="locality">{$oUserProfile->getProfileCity()|escape:'html'}</a>
{/if}
</strong>
</li>

View file

@ -107,7 +107,7 @@
{include file='nav.tpl'}
<div id="wrapper" {if $noSidebar}class="no-sidebar"{/if}>
<div id="content" role="main" {if $sidebarPosition == 'left'}class="content-profile"{/if}>
<div id="content" role="main" {if $sidebarPosition == 'left'}class="content-profile"{/if} {if $sMenuItemSelect=='profile'}itemscope itemtype="http://data-vocabulary.org/Person"{/if}>
{include file='nav_content.tpl'}
{include file='system_message.tpl'}

View file

@ -1,6 +1,8 @@
jQuery(document).ready(function($){
// Хук начала инициализации javascript-составляющих шаблона
ls.hook.run('ls_template_init_start',[],window);
$('body').removeClass('no-js');
// Всплывающие окна
$('#window_login_form').jqm();

View file

@ -17,4 +17,7 @@ return array(
'blog_join' => 'Читать',
'blog_expand_info' => 'О блоге',
'blog_fold_info' => 'Свернуть',
'profile_about_empty' => 'Пока ничего не известно...',
'profile_about_edit' => 'Редактировать',
);