date registerd in post

Started by Chaos Dragon, September 15, 2008, 11:58:04 PM

Previous topic - Next topic

Chaos Dragon

Link to Mod

This mod will display a member's date registerd next to their posts

if you theme has its own  display.template.php

find
echo '
', $txt[231], ': ', $message['member']['gender']['image'], '<br />';



after add

if ($message['member']['registered'] != '')
echo '
', $txt['Date_Registerd'], ':', $message['member']['registered'], '<br />';
"Never stop exploring new ideas, concepts and techniques, but never forget the old ones, they just may come in handy someday!"
"Don't give up! Otherwise you do not win and nothing gets accomplished!"
Einstein "Insanity is doing the same thing over and over again, and expecting different results..."
Do Not PM me for Support. They will be Ignored. Use the Threads the have been provided.

brandonroy

I like this alot. It's simple and I never thought of it not being there in SMF by default. However, I'd like to change a few things. I'd like the format to be like this:

Join Date: June 2008

I don't want it to show the exact time or anything. I'd like it to look just like the above! How can I do it?

SA™

im shore it can be done how i dont know yet im of to work now if you can wait ill have a playe aroumd tonight for ya unless you can work it iout
http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-

brandonroy

I'm not exactly sure how. But I did change the word "Date Registered" to "Join Date" in the themes/default/languages/index.english.php file. I just want to shorten it up and take out the time format. I'll wait on you or someone else. If not, I'll play around with it later (it's 5:39 in the morning right now) o_-

Thanks again!

babjusi

Quote from: brandonroy on September 16, 2008, 06:21:13 AM
I like this alot. It's simple and I never thought of it not being there in SMF by default. However, I'd like to change a few things. I'd like the format to be like this:

Join Date: June 2008

I don't want it to show the exact time or anything. I'd like it to look just like the above! How can I do it?

Try something like this.

Find:

echo '
                        ', $txt[231], ': ', $message['member']['gender']['image'], '<br />';


And after it add the following code:

// This will show the date that the user registered
      echo 'Join Date: ', strftime('%b %Y', $message['member']['registered_timestamp']), '<br />';


Let me know if this is what you wanted

brandonroy



SA™

http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-


timned88

just for the heck of it, the word registered is spelled wrong in index.english.php.  otherwise, cool mod.

Matthew Schenker

Thanks for this mod!  It's a nice, simple addition that helps members know a bit more about each other.

By the way, here's how I made this work, which may help others wanting to do the same thing:

After this section...
// Show the member's gender icon?
            if (!empty($settings['show_gender']) && $message['member']['gender']['image'] != '')
                echo '
                                ', $txt[231], ': ', $message['member']['gender']['image'], '<br />';


Add this...
// This will show the date that the user registered
            echo 'Member Since: ', strftime('%b %Y', $message['member']['registered_timestamp']), '<br />';


Thanks again for doing this!

Matthew

Snap_shot

Will this ever be updated to beta 4?

SA™

http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-

MaXiForum.cz

THX good mod :)

      // Show registr date                 
if ($message['member']['registered'] != '')
echo '
', $txt['Date_Registerd'], ': ', strftime('%d. %m. %Y', $message['member']['registered_timestamp']), '<br />';
      // ===== End modification =====


vivithemage


bullbreedluverz

Quote from: Matthew Schenker on September 17, 2008, 06:04:27 PM
Thanks for this mod!  It's a nice, simple addition that helps members know a bit more about each other.

By the way, here's how I made this work, which may help others wanting to do the same thing:

After this section...
// Show the member's gender icon?
            if (!empty($settings['show_gender']) && $message['member']['gender']['image'] != '')
                echo '
                                ', $txt[231], ': ', $message['member']['gender']['image'], '<br />';


Add this...
// This will show the date that the user registered
            echo 'Member Since: ', strftime('%b %Y', $message['member']['registered_timestamp']), '<br />';


Thanks again for doing this!

Matthew

cool this worked perfect to give month & year of registration

ManilaGurL

How do I know if my theme has it's own display.template.php? Admin > Themes and Layout Settings > Modify Themes?

SA™

http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-

ManilaGurL

I am using DilberMC with TinyPortal.

SA™

you should be ok that dont have an display.template.php
http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-

Advertisement: