Advertisement:

Author Topic: Relative Dates  (Read 32804 times)

Online vbgamer45

  • Customizer
  • SMF Super Hero
  • *
  • Posts: 23,475
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Relative Dates
« on: February 07, 2010, 11:32:08 PM »
Link to Mod

Relative Dates


Original Author:live627
SMF Version: 2.0.X
Mod Version: 1.3

Description:
This mod, when enabled, converts the usual date displays for posts with a relative one, such as 2 minutes ago, 7 hours ago, etc.

It isn't on by default; setting is in AdminCP => Features and Options => Layout.

Changelog
Version 1.3
! Taken over by Runic
! Updated for 2.0.x
- Removed support for 1.1

Version 1.2
! Should be 0 seconds ago, not in 0 seconds
* Commenazi
+ Silently disables itself in XML mode. To turn it back on in XML, read my post.
* Converting all line endings to LF

Version 1.1
+ Added 1.1.x support
! Fixed vanishing "ago"
! Fixed future "negative" date bug
+ Extends relativity into the future, i.e, tomorrow


Legend:
--------------------------------------------------------------------------------
 ! Minor change or bugfix
 * Feature edit
 & Known bug
 + Feature addition
 - Feature removal
 
Why Not Visit:
http://www.smfhacks.com
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline Tanks

  • Full Member
  • ***
  • Posts: 583
  • Gender: Male
  • Danish Dude
Re: Relative Dates
« Reply #1 on: February 08, 2010, 02:31:03 AM »
I don't think it works on my 2.0 RC2

It says: 1453 seconds ago , by Knat Simon

Offline live627

  • Developer
  • SMF Hero
  • *
  • Posts: 5,918
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Relative Dates
« Reply #2 on: February 09, 2010, 12:05:01 PM »
Hmm, thanks for pointing that out. I fixed the problem and reuploaded it

Offline sAce

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 2,992
    • @sbplus_t on Twitter
    • SB+
Re: Relative Dates
« Reply #3 on: February 10, 2010, 03:03:14 AM »
nice mod live, good work

Offline Tanks

  • Full Member
  • ***
  • Posts: 583
  • Gender: Male
  • Danish Dude
Re: Relative Dates
« Reply #4 on: February 10, 2010, 05:40:45 AM »
That fixed it, but i still see something that i think is wrong.

1. Minutes ago is right, hours ago is right, but 1 hour ago is missing the "ago"

2. It should be bold like the today and yesterday is.

Could you fix these two things then i would love to use your mod.

Cheers, and thanks :)

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,659
  • Gender: Male
    • dragomano on GitHub
    • Support me on Ko-fi
Re: Relative Dates
« Reply #5 on: February 10, 2010, 08:20:44 AM »
What's the problem? (see attachment)

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,659
  • Gender: Male
    • dragomano on GitHub
    • Support me on Ko-fi
Re: Relative Dates
« Reply #6 on: February 10, 2010, 08:22:05 AM »
Russian translation:

Code: [Select]
$txt['hours'] = 'часов';
$txt['minutes'] = 'минут';
$txt['seconds'] = 'секунд';
$txt['hour'] = 'час';
$txt['minute'] = 'минута';
$txt['second'] = 'секунда';
$txt['ago'] = 'назад';
$txt['relative_today'] = 'Сегодня с относительным временем';

Offline h78509

  • Semi-Newbie
  • *
  • Posts: 34
Re: Relative Dates
« Reply #7 on: February 11, 2010, 05:33:30 PM »
I installed this on my 2.0 RC2 Curve but unfortunately there was no option to enable it.

Offline live627

  • Developer
  • SMF Hero
  • *
  • Posts: 5,918
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Relative Dates
« Reply #8 on: February 11, 2010, 11:46:23 PM »
Look at a screenshot on the mod page

It is there for anyone who can read :D

Offline Tanks

  • Full Member
  • ***
  • Posts: 583
  • Gender: Male
  • Danish Dude
Re: Relative Dates
« Reply #9 on: February 15, 2010, 01:39:46 AM »
Hello Live627,

Did you look into the thing in my post above ?

TheListener

  • Guest
Re: Relative Dates
« Reply #10 on: February 16, 2010, 09:53:57 PM »
Great addition Live.

Installed within seconds on the forum.

( Raven Theme)

Offline live627

  • Developer
  • SMF Hero
  • *
  • Posts: 5,918
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Relative Dates
« Reply #11 on: February 22, 2010, 12:31:41 AM »
Update: 1.1 fixes all reported bugs

TheListener

  • Guest
Re: Relative Dates
« Reply #12 on: February 22, 2010, 09:15:10 PM »
Did you try the settings as mentioned in the first post?

Offline live627

  • Developer
  • SMF Hero
  • *
  • Posts: 5,918
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Relative Dates
« Reply #13 on: February 22, 2010, 09:31:56 PM »
Quote from: Bugo link=topic=364742.msg2495393#msg2495393 date=
Russian translation
[/quote

Is it utf8, or otherwise, or both?

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,659
  • Gender: Male
    • dragomano on GitHub
    • Support me on Ko-fi
Re: Relative Dates
« Reply #14 on: February 23, 2010, 03:56:26 AM »
Updated russian translation.
Add this files to install package :)

Offline live627

  • Developer
  • SMF Hero
  • *
  • Posts: 5,918
  • Gender: Male
    • live627 on Facebook
    • live627 on GitHub
    • live627 on LinkedIn
    • @live627 on Twitter
    • livemods
Re: Relative Dates
« Reply #15 on: February 23, 2010, 11:22:14 PM »
Thank you Bugo

Offline Özgür

  • SMF Hero
  • ******
  • Posts: 3,926
  • Gender: Male
  • Özgür | jQuery Lover
    • ozgurce on Facebook
    • @ozgurce on Twitter
    • Özgür Yalçın
Re: Relative Dates
« Reply #16 on: February 27, 2010, 12:31:13 PM »
Turkish translation
Code: [Select]
$txt['hours'] = 'saat';
$txt['minutes'] = 'dakika';
$txt['seconds'] = 'saniye';
$txt['hour'] = 'saat';
$txt['minute'] = 'dakika';
$txt['second'] = 'saniye';
$txt['ago'] = 'önce';
$txt['in'] = 'içinde';// need to be test.
$txt['relative_today'] = 'Bugün ve göreceli zamanlar';
So Long

Offline rahlzel

  • Semi-Newbie
  • *
  • Posts: 14
Re: Relative Dates
« Reply #17 on: March 10, 2010, 12:00:27 AM »
Still works fine for RC3, though as a new user it was a little difficult to find. You mentioned the Features and Options > Layout section, which is where I found it, but I don't come to this section much so I assumed the default option "Only Today" means it was supposed to be "On".

I almost came here to post a bug report until I happened upon the last setting, "...with relative times", which did the trick.

Great idea for a mod, but you might want to make it a bit simpler to come across. Maybe have it automatically use this setting as soon as it's installed?

Thank you, and well done!

Offline Eclipse16V

  • Sophist Member
  • *****
  • Posts: 1,070
  • Gender: Male
  • Tornado Map
    • Eclipse16V on Facebook
    • @Eclipse16V on Twitter
    • SID Giessen
Re: Relative Dates
« Reply #18 on: March 15, 2010, 02:15:42 AM »
Nice Mod

Please update it for SMF 2.0RC3  ;)

Thanks
I worked with:
SMF 2 in German

Shop:
SID Giessen

Offline Afro

  • SMF Hero
  • ******
  • Posts: 1,855
  • Gender: Male
  • http://twitter.com/afrowall
    • Global Runs
Re: Relative Dates
« Reply #19 on: March 15, 2010, 05:14:23 PM »
Good Mod.
Weldone.