News:

Want to get involved in developing SMF? Why not lend a hand on our GitHub!

Main Menu

Order of items in mini-profile (postbit?)

Started by Steve, August 09, 2015, 06:32:41 PM

Previous topic - Next topic

Steve


I can just move sections of code in display.template.php to order the items in the mini-profile or postbit or whatever it's actually called in topic view, without messing anything up anywhere else, right?

My pet rock is not feeling well. I think it's stoned.

Illori

moving code does not effect anything but the code you are moving. so the display would stay the same in the profile view.

now if they are custom profile fields you cannot just move code around to change their position.
http://custom.simplemachines.org/mods/index.php?mod=1328 will allow you to do that.

Steve

Interesting but I easily moved the only custom field I have (Location:) up a couple of places from the bottom where it originally showed up at. (see attached)

I moved this code to above the Country Flag code and everything seems to work fine:

// Any custom fields for standard placement?
if (!empty($message['member']['custom_fields']))
{
foreach ($message['member']['custom_fields'] as $custom)
if (empty($custom['placement']) || empty($custom['value']))
echo '
<li class="custom">', $custom['title'], ': ', $custom['value'], '</li>';
}


Am I correct in saying that if I have more than one custom field I can't do that, and instead need to use the mod you posted?
My pet rock is not feeling well. I think it's stoned.

Illori

yes exactly. otherwise the custom profile fields will be in alpha order.

Steve

My pet rock is not feeling well. I think it's stoned.

Advertisement: