The website is for sale. Check here for more information.
This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.
How to? Post date change
#1
Hello all,

When posting it will give a date.
Example when somebody posted a week ago it will appear as '8-06-2014'.

Is there a way I can turn this date into 'A week ago' ?
I'm not a PHP Developer so I'm wondering how hard this is to make.

Been browsing through the docs and came across this.
http://php.net/manual/en/function.strtotime.php
Is that related?

Anyhow, if somebody could tell me how to do this it would be appreciated.
Would also not mind paying a small fee for it.

Thanks!
Reply
#2
You will need to use relative time. MyBB 1.8 comes with it.
http://www.php.net//manual/en/datetime.f...lative.php
http://stackoverflow.com/questions/26905...timestamps
http://gilbert.pellegrom.me/php-relative-time-function/
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#3
(06-15-2014, 07:29 PM)Pirata Nervo Wrote: You will need to use relative time. MyBB 1.8 comes with it.
http://www.php.net//manual/en/datetime.f...lative.php
http://stackoverflow.com/questions/26905...timestamps
http://gilbert.pellegrom.me/php-relative-time-function/

Thank you for your quick reply.
I'll wait it out then, thanks! Big Grin
Reply
#4
No problem Smile
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#5
(06-15-2014, 09:03 PM)Pirata Nervo Wrote: No problem Smile

and if i would to come back to a previous way, linke instead "6 hours ago" i would have "9.55.00"

is it still possibile with 1.8?
Reply
#6
Yes, you need to set the my_date parameter related to date format to the format you want.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#7
(01-08-2015, 01:10 AM)Pirata Nervo Wrote: Yes, you need to set the my_date parameter related to date format to the format you want.

and where i found this parameter and how i change it?

(right now i've installed a plugin who solve the problem.  http://doylecc.altervista.org/en/time.html ) but if i may not use a plugin is even better. Big Grin

thank you again for your help
Reply
#8
Oh I'm sorry but this is not for support related to MyBB features but actually coding help. If you want support for general stuff, you need to subscribe.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#9
(01-08-2015, 03:01 AM)Pirata Nervo Wrote: Oh I'm sorry but this is not for support related to MyBB features but actually coding help. If you want support for general stuff, you need to subscribe.

Thank for the previous help and for this information.
Reply





Users browsing this thread: 1 Guest(s)

About MyBB-Plugins

Plug Yourself into the best MyBB AddOn.

Copyright © 2009-2021 MyBB-Plugins Forums.

Statistics

  • 51,000+ Posts
  • 19,000+ Members
  • 3,600+ Threads

Impressed? For sure
Check Full Stats here