Donators group showing up on Website Credits page

Jurien

  • All i want is a couple days off
  • Posts: 132
Donators group showing up on Website Credits page
« on August 26th, 2016, 11:28 AM »
Wanted to give our donators an more prominent place on our Website Credits page,in the same way as moderators are shown up.

So far did these two adjustments, but still no luck,do I forget something or doing something wrong.

Who.template.php
  if (!empty($context['site_credits']['donations']))
{

echo '
<section>
<h6>'
number_context('credits_donateurs'count($context['site_credits']['donations'])), '</h6>
<ul class="last">'
;

foreach ($context['site_credits']['donations'] as $donation)
echo '
<li'
strpos($donation['real_name'], '<img') !== false ' class="witha"' '''><a href="<URL>?action=profile;u='$donation['id_member'], '">'$donation['real_name'], '</a></li>';

echo '
</ul>
</section>'
;
}

Who.dutch.php
// Credits text
$txt['credits_site'] = 'Team-leden';
$txt['credits_admins'] = array(=> 'Administrator''n' => 'Beheerders');
$txt['credits_moderators'] = array(=> 'Moderator''n' => 'Moderators');
$txt['credits_donations'] = array(=> 'Donation''n' => 'Donateurs');

Nao

  • Dadman with a boy
  • Posts: 16,079

Jurien

  • All i want is a couple days off
  • Posts: 132

CerealGuy

  • Posts: 343

Jurien

  • All i want is a couple days off
  • Posts: 132
Re: Donators group showing up on Website Credits page
« Reply #4, on August 27th, 2016, 04:11 PM »
Thanks CerealGuy
Started all over again and gives it all Dutch names Who.dutch.php,Who.template.php,at last added donateurs in
Credits.php like this
// It's nicer with avatars, really...
loadMemberData(array_keys($site_team));
foreach ($site_team as $member => $row)
{
if (empty($memberContext[$member]['avatar']))
loadMemberAvatar($membertrue);
$row['real_name'] = (empty($memberContext[$member]['avatar']['image']) ? '' $memberContext[$member]['avatar']['image']) . $row['real_name'];
$context['site_credits'][$row['id_group'] == || (!empty($row['additional_groups']) && in_array(1explode(','$row['additional_groups']))) ? 'admins' 'mods' 'donateurs' ][] = $row;
}

Still no go,even worse Website Credit page won't load or open at all
Re: Donators group showing up on Website Credits page
« Reply #5, on August 29th, 2016, 11:15 AM »
It seems that the additional_groups name donateurs (membersgroup 12)  won´t be regonized the same way as admins and mods,have no clue why ?.

The only thing that rest my is to created group donateurs in Who.template.php
<we:cat>
', $txt['credits_donateurs'], '
</we:cat>

<we:block class="windowbg2">';
$i = 1;
$max = count($context['
credits']);

foreach ($context['
credits'] as $group)
echo '
<section>
<h6>', $group['title'], '</h6>
<ul', $i === $max ? ' class="last"' : '', '>
<li>', implode('</li>
<li>', $group['members']), '</li>
</ul>
</section>';

and add a Credits text in Who.dutch.php and fill in the names of our donators.

$txt['credits_donateurs'] = 'Donateurs :';

However that's not what i wanted in the first place (Goal is to see donators by name and avatar,the same way as admins and moderators are been showed)