TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 884
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 371
  • Total: 371

How is TP Team page created??

Started by mandos, October 02, 2006, 07:01:20 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Tommy

#30
Okay now all team member nicks are linked to their article. But what is wrong?:
$context['TPortal']['team'][] = array(
                'member_page' => empty($member_boards[$row['ID_MEMBER']]) ? '' : '<a href="' . $scripturl . '?page=' . $member_boards[$row['ID_MEMBER']] . '"><u> ' . $row['realName'],
'name' => $row['realName'],
'groupname' => $groupname,
'posts' => $row['posts'],
'location' => $row['location'],
'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
'link' => '<a href="' . $scripturl . '?action=profile;u=' . $row['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $row['realName'] . '">' . $row['realName'] . '</a>',
'blurb' => $row['personalText'],
'avatar' => array(
'name' => $row['avatar'],
'image' => $row['avatar'] == '' ? ($row['ID_ATTACH'] > 0 ? '<img  src="' . (empty($row['attachmentType']) ? $scripturl . '?action=dlattach;attach=' . $row['ID_ATTACH'] . ';type=avatar' : $modSettings['custom_avatar_url'] . '/' . $row['filename']) . '" alt="" class="avatar2" border="0" />' : '') : (stristr($row['avatar'], 'http://') ? '<img src="' . $row['avatar'] . '"' . $avatar_width . $avatar_height . ' alt="" class="avatar2" border="0" />' : '<img src="' . $modSettings['avatar_url'] . '/' . htmlspecialchars($row['avatar']) . '" alt="" class="avatar2" border="0" />'),
'href' => $row['avatar'] == '' ? ($row['ID_ATTACH'] > 0 ? (empty($row['attachmentType']) ? $scripturl . '?action=dlattach;attach=' . $row['ID_ATTACH'] . ';type=avatar' : $modSettings['custom_avatar_url'] . '/' . $row['filename']) : '') : (stristr($row['avatar'], 'http://') ? $row['avatar'] : $modSettings['avatar_url'] . '/' . $row['avatar']),
'url' => $row['avatar'] == '' ? '' : (stristr($row['avatar'], 'http://') ? $row['avatar'] : $modSettings['avatar_url'] . '/' . $row['avatar'])
),
'last_login' => empty($row['lastLogin']) ? $txt['never'] : timeformat($row['lastLogin']),
'last_login_timestamp' => empty($row['lastLogin']) ? 0 : forum_time(0, $row['lastLogin']),
'website' => array(
'title' => $row['websiteTitle'],
'url' => $row['websiteUrl']),
'online' => array(
'is_online' => $row['isOnline'],
'text' => &$txt[$row['isOnline'] ? 'online2' : 'online3'],
'image_href' => $settings['images_url'] . '/' . ($row['isOnline'] ? 'useron' : 'useroff') . '.gif',
),
'teamtext' => $row['teamtext']. '</u></a>',






<td valign="top">'.$team['avatar']['image'].'</td>
<td valign="top" width="50%" class="middletext" style="padding: 5px;">
<h2 style="margin-top: 0; margin-bottom: 6px;">  '.$team['member_page'].'</h2>
<b>Zuletzt online</b>: '.$team['last_login'].'<br />
<b>BeitrÃÆ'Ã,¤ge</b>: '.$team['posts'].'<br />
' , !empty($team['location']) ? '<b>Wohnort</b>: '.$team['location'].'<br />' : '' , '
' , !empty($team['website']['title']) ? '<b>Webseite</b>: <a href="'.$team['website']['url'].'" target="_blank">'.$team['website']['title'].'</a><br />' : '' , '
' ,  $team['online']['is_online'] ? '<img src="'.$team['online']['image_href'].'" alt="" /> '.$team['online']['text'].'<br />' : $team['online']['text'].'<br />' , '

' , !empty($team['blurb']) ? '<i>- '.$team['blurb'].'</i><br />' : '' , '

' ,  !empty($team['teamtext']) ? $team['teamtext'].'<br />' : '' , '


Not only the nick is a link - all Text (Location, website, ...) is a link to their article  :-\

jacortina

Quote from: Raven on October 15, 2006, 12:41:10 PM
Please forgive my stupidity if this is obviouse...

http://www.bzfiend.com/raven/forum/index.php?page=5

This is all I get, the 4 primary membergroupd are selected (I think)
////////////////////////////////////////  Enter the desired groups - in order of appearance, if listing by group
$groups_list = array(1, 4, 2, 3);
////////////////////////////////////////


Admin, Global, Moderator and BETA Tester. I hope...

So yeah, what on earth is going on with this? Nothing is showing ???

Group 4 'should' be your Newbie post count group (that's defined by SMF out-of-the-box).

Group 3 should be moderators, but you still have to enable them by the program 'switch' (set $include_moderators = true).

More importantly. just put in fix for what appears to be a MySQL versioning issue.

Code working fine on my site mirror on my PC wasn't even working on my own live site. ;)

Changing from the implied JOIN type to explicit for the moderator's table appears to have fixed it. Have changed the code in the message:

http://www.tinyportal.net/smf/index.php?topic=8555.msg79951#msg79951

Try it and see if that straightens it out.

jacortina

#32
Quote from: Dubidu on October 15, 2006, 01:04:49 PM
$context['TPortal']['team'][] = array(
                'member_page' => empty($member_boards[$row['ID_MEMBER']]) ? '' : '<a href="' . $scripturl . '?page=' . $member_boards[$row['ID_MEMBER']] . '"><u> ' . $row['realName'],
...
'teamtext' => $row['teamtext']. '</u></a>',

You don't close the link tag until the end (until teamtext is displayed and because it will now never be empty, you'll always display it.

Raven

Hmm, how can I see what number the membergroups are?

Still blank even with that code and moderators enabled.
I just suck with this stuff :P

Kiwitje

If you have cPanel, you can see it in PHPmyadmin

jacortina

Quote from: Raven on October 15, 2006, 07:43:32 PM
Hmm, how can I see what number the membergroups are?

Still blank even with that code and moderators enabled.
I just suck with this stuff :P
Admin -> Membergroups

clicking on the Modify link to the far right for the group you want will open up a the edit with a link in your browser address area ending:
index.php?action=membergroups;sa=edit;group=##

Premade groups (SMF out-of-the-box):
1 - Admin
2 - Global Moderator
3 - Moderator
4-8 Post Count Groups Newbie through Hero Member.

Hate to ask, but do you have any members actually assigned as board moderators?

Raven

Perhaps not, it is a small board. There are groups that are primary and assigned, I did that method before but wasn;t sure if it was right, it was so hopefully it will work this time...

I am using a friends site for the forum as I need to upgrade mine, I bought the lowest of low, doesn't have a database or nothing :P What can I expect for ÂÃ,£30 for two years :P Then again, I have access to the cPanel so most likely PHPmyadmin too.

EDIT:

SCORE! *Ahem* it worked.

Tommy

Quote from: jacortina on October 15, 2006, 02:19:16 PM
Quote from: Dubidu on October 15, 2006, 01:04:49 PM
$context['TPortal']['team'][] = array(
                'member_page' => empty($member_boards[$row['ID_MEMBER']]) ? '' : '<a href="' . $scripturl . '?page=' . $member_boards[$row['ID_MEMBER']] . '"><u> ' . $row['realName'],
...
'teamtext' => $row['teamtext']. '</u></a>',

You don't close the link tag until the end (until teamtext is displayed and because it will now never be empty, you'll always display it.


Aah okay - thx. I copied this link tag from another position.. :) Thx :)

OzButcher

Is there a way to display users from additional member groups? Example:

Person1 = Admin (Primary Member Group)
           = Tactical Group (Additional Member Group)

Currently: Only primary group users are displayed. in this case Person1 only shows up in the admin group but not the tactical group.

cheers

jacortina

What code are you using?

If you are using the code I posted in:
http://www.tinyportal.net/index.php?topic=8555.msg79951#msg79951

then you first need to make sure that both the admin group and the
tactical group are included in the $groups_list = array(##,##)

You also need to set:
$include_nonprimary_groups = true;
$repeats_allowed = true;

(the last one there is what allows a person to show up more than
once on the page).

This website is proudly hosted on Crocweb Cloud Website Hosting.