/* Query for the motm? */
$this->DB->build( array( 'select' => '*', 'from' => 'HQ_motm', 'order' => 'id DESC' ) );
$this->DB->execute();
while( $query = $this->DB->fetch() )
{
$motm[] = $query;
}
if (isset($motm))
{
$amotm = IPSMember::buildDisplayData( $motm[0]['m_id'] );
$month = $motm[0]['month'];
$lprof = IPSMember::makeProfileLink( $motm[0]['username'], $amotm['member_id'], $amotm['members_seo_name'] );
$output = $this->registry->output->getTemplate('boards')->hookMotm( $amotm,$days,$ratio,$photo,$fname,$joined,$online,$month,$lprof,$award_display,$count,$addnote );
return $output;
if (isset($motm))
{
$amotm = IPSMember::buildDisplayData( $motm[0]['m_id'] );
$month = $motm[0]['month'];
if ( $amotm['_online'] == 0 )
{
$online = sprintf($this->lang->words['motm_offline'],$amotm['_last_active']);
} else {
$online = $this->lang->words['motm_online'];
}
$lprof = IPSMember::makeProfileLink( $motm[0]['username'], $amotm['member_id'], $amotm['members_seo_name'] );
$output .= $this->registry->output->getTemplate('boards')->hookMotmSide( $amotm,$days,$ratio,$photo,$fname,$joined,$online,$month,$lprof,$award_display,$count,$addnote );
return $output;
if (isset($motm))
{
$amotm = IPSMember::buildDisplayData( $motm[0]['m_id'] );
$month = $motm[0]['month'];
$output = $this->registry->output->getTemplate('boards')->hookMotm( $amotm,$days,$ratio,$photo,$fname,$joined,$online,$month,$lprof,$award_display,$count,$addnote );
return $output;
<div style="border-bottom:1px solid lightgrey;padding-bottom:3px;">
<h4> <span style="font-size:1.3em;">{$lprof}</span>
<span style="float:right;color:grey;font-size:10px;position:relative;">{$this->lang->words['motm_title']}: <span class="ipsBadge" style="background:green;">{$month}</h4>
</div>
<p class="desc __forum_desc ipsType_small" style="padding-top:3px">
{parse expression="sprintf($this->lang->words['motm_text'],$amotm['members_display_name'],$month,$joined,$days,$amotm['posts'],$ratio,$amotm['members_profile_views'],$amotm['pp_reputation_points'],$amotm['pp_rating_hits'],$online)"}
</p>
<template_data>$amotm,$days,$ratio,$photo,$fname,$joined,$online,$month,$lprof,$award_display,$count,$addnote</template_data>
<span style="color:grey;font-size:10px;position:relative;">{$this->lang->words['motm_title']} </span><span class="ipsBadge" style="background:green;">{$month}
</span>
<p class="desc __forum_desc ipsType_small" style="padding-top:3px;font-size:10px;text-align: justify; text-justify: newspaper">
{parse expression="sprintf($this->lang->words['motm_text'],$amotm['members_display_name'],$month,$joined,$days,$amotm['posts'],$ratio,$amotm['members_profile_views'],$amotm['pp_reputation_points'],$amotm['pp_rating_hits'],$online)"}
</p>
<template_data>$amotm,$days,$ratio,$photo,$fname,$joined,$online,$month,$lprof,$award_display,$count,$addnote</template_data>
Oto wszystkie fragmenty ze zmienną $month
Mam nadzieję że dobrze dałem kody i nie pominąłem jakiejś linijki