Advertisement:

Author Topic: Profile Information  (Read 5098 times)

Offline SpectroPro

  • Jr. Member
  • **
  • Posts: 376
  • Gender: Male
    • The Reality Rocks Group
Profile Information
« on: October 16, 2004, 09:11:44 PM »
How can I get the posts to show a persons location?  In other words, when people post, you see their name, avatar, message options (yahoo, icq, aim, etc...), Karma, gender, posts, etc...   I would like to see, in that area, the location they put in their profile.    On my board, we ask that they put in their location their local airport name so that we can fly there in flight simulators. 

I would like this info to be shown above or under their avatar.  How can I accomplish this?

TIA
Stats:  SMF v. 2b4  -  Mambo v4.65  -  Bridge v2.0b1

http://www.therealityrocks.com    http://forum.therealityrocks.com/trr
- Greg

Offline [Unknown]

  • SMF Friend
  • SMF Master
  • *
  • Posts: 36,102
  • Gender: Male
Re: Profile Information
« Reply #1 on: October 16, 2004, 10:35:20 PM »
It's just $message['member']['location'].

For example, find this in Themes/yourtheme/Display.template.php:
Code: [Select]
// Show their personal text?
if (!empty($settings['show_blurb']) && $message['member']['blurb'] != '')
echo '
', $message['member']['blurb'], '<br />
<br />';

And add above it:

         // Show their personal text?
         if (!empty($message['member']['location']))
            echo '
                        ', $message['member']['location'], '<br />';

-[Unknown]

Offline SpectroPro

  • Jr. Member
  • **
  • Posts: 376
  • Gender: Male
    • The Reality Rocks Group
Re: Profile Information
« Reply #2 on: October 16, 2004, 10:55:03 PM »
Excellant!!!!  Thank you.  That was almost too easy.   :D

I did this format which made it a bit cleaner. 

// Show their location?
            if (!empty($message['member']['location']))
                echo 'Location: 
            <br />
                        ', $message['member']['location'], '<br />
                  <br />';

You all rule as usual!  Now, If I can just get my main site page fixed with the recent posts info...all will be great with the world...  well, until the next problem.   ;)
Stats:  SMF v. 2b4  -  Mambo v4.65  -  Bridge v2.0b1

http://www.therealityrocks.com    http://forum.therealityrocks.com/trr
- Greg

Offline bd2003

  • Semi-Newbie
  • *
  • Posts: 20
    • MVOhio.Net - your source for... stuff.
Re: Profile Information
« Reply #3 on: January 11, 2005, 12:15:43 PM »
I tweaked it just a tad bit more with:

           if (!empty($message['member']['location']))
                   echo '<b>Location: <br />',
                            $message['member']['location'], '</b><br /><br />';
           else echo '<b>Location:<br />
                            Hopelessly Lost</b><br /><br />';


Just so some users wouldn't feel left out...

btw - just moved from IPB, and I can't believe the difference! Great job, guys...

Offline [Unknown]

  • SMF Friend
  • SMF Master
  • *
  • Posts: 36,102
  • Gender: Male
Re: Profile Information
« Reply #4 on: January 12, 2005, 04:01:45 AM »
Thanks, glad you got it how you wanted it ;).

-[Unknown]

Offline maritimesbob

  • Jr. Member
  • **
  • Posts: 102
Re: Profile Information
« Reply #5 on: July 30, 2006, 10:39:33 PM »
I wouldn`t mind using this tweak, but unfortunately the theme that I`m using does not have a Display.template.php file. I`m using the Oxygen theme from Bloc.

Offline 青山 素子

  • Server Team
  • SMF Super Hero
  • *
  • Posts: 17,020
  • 戦場ヶ原、蕩れ!
    • srvrguy on GitHub
    • @motokochan on Twitter
    • Nekomusume Moe
Re: Profile Information
« Reply #6 on: July 30, 2006, 10:56:52 PM »
That means it uses display.template.php from the default theme. You can either edit that file directly or make a copy and put it into the directory of the theme you are using.
Motoko-chan
Director, Simple Machines

Just because it's pouring down doesn't mean we're gonna drown. There's a time when all you can say is let it rain - Mat Kearney (Let It Rain)

Note: Unless otherwise stated, my posts are not representative of any official position or opinion of Simple Machines.