- Posts: 40
COMMUNITY FORUM
[SOLVED] Display item creation date and year
- Eugen
-
Topic Author
- Offline
- Senior Member
Less
More
10 years 8 months ago #131763
by Eugen
[SOLVED] Display item creation date and year was created by Eugen
Hello,
On English demo site i see items have creation date AND YEAR displayed:
websitedev2.uni.me/index.php?option=com_k2&view=latest&layout=latest&Itemid=453
While on my site (Russian & Romanian) items have only month date displayed:
www.principiuldivin.md/ro/blog
Any ideas what options or files should i check to get the year displayed?
Thanks a lot.
On English demo site i see items have creation date AND YEAR displayed:
websitedev2.uni.me/index.php?option=com_k2&view=latest&layout=latest&Itemid=453
While on my site (Russian & Romanian) items have only month date displayed:
www.principiuldivin.md/ro/blog
Any ideas what options or files should i check to get the year displayed?
Thanks a lot.
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
-
- Offline
- Platinum Member
Less
More
- Posts: 15920
10 years 8 months ago #131764
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Display item creation date and year
Hello.
Please read this post.
getk2.org/community/English-K2-Community/182596-How-to-change-date-format-in-blog-posts#182604
Please read this post.
getk2.org/community/English-K2-Community/182596-How-to-change-date-format-in-blog-posts#182604
Please Log in or Create an account to join the conversation.
- Eugen
-
Topic Author
- Offline
- Senior Member
Less
More
- Posts: 40
10 years 8 months ago - 10 years 8 months ago #131765
by Eugen
Replied by Eugen on topic Re: Display item creation date and year
I have read the post and searched through all my files, and i see this in all language .ini files, English, Russian and Romanian:
Log in or Create an account to join the conversation.
- Krikor Boghossian
-
- Offline
- Platinum Member
Less
More
- Posts: 15920
10 years 8 months ago #131766
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Display item creation date and year
I think you have some errors in your syntax.
You need to double check your values according to this: php.net/manual/en/function.date.php
You need to double check your values according to this: php.net/manual/en/function.date.php
Please Log in or Create an account to join the conversation.
- Eugen
-
Topic Author
- Offline
- Senior Member
Less
More
- Posts: 40
10 years 8 months ago - 10 years 8 months ago #131767
by Eugen
Replied by Eugen on topic Re: Display item creation date and year
Could you please mention more specific what syntax in which file?
I have created my own format according to php.net/manual/en/function.date.php, and tried both:
I have created my own format according to php.net/manual/en/function.date.php, and tried both:
Log in or Create an account to join the conversation.
- Krikor Boghossian
-
- Offline
- Platinum Member
Less
More
- Posts: 15920
10 years 8 months ago #131768
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Display item creation date and year
The first one seems fine.
Did you use language overrides (one for each language)?
docs.joomla.org/J2.5:Language_Overrides_in_Joomla
If you didn't then you should because your changes will be lost when you updaate.
Did you use language overrides (one for each language)?
docs.joomla.org/J2.5:Language_Overrides_in_Joomla
If you didn't then you should because your changes will be lost when you updaate.
Please Log in or Create an account to join the conversation.
- Eugen
-
Topic Author
- Offline
- Senior Member
Less
More
- Posts: 40
10 years 8 months ago #131769
by Eugen
Thank you.
Replied by Eugen on topic Re: Display item creation date and year
I have tried it, but it did not change anything. Am i applying it to wrong files?Krikor Boghossian wrote: The first one seems fine.
As soon as i will see it working straight I'll apply it as an override.Krikor Boghossian wrote: Did you use language overrides (one for each language)?
Thank you.
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
-
- Offline
- Platinum Member
Less
More
- Posts: 15920
10 years 8 months ago #131770
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Display item creation date and year
the language files are located at: languages/en-GB(or ru-RU etc..)/com_k2.ini
You need to change these strings:
K2_DATE_FORMAT="%d/%m/%Y - %H:%M"
K2_DATE_FORMAT_LC2="%A, %d %B %Y %H:%M"
K2_DATE_FORMAT_LC="%A, %d %B %Y"
For the administrator lang files the path is /adminstrator/languages/....
Check your site using the system template (by using ?template=system as a URL suffix) to make sure that the template developer has not replace these default strings.
You need to change these strings:
K2_DATE_FORMAT="%d/%m/%Y - %H:%M"
K2_DATE_FORMAT_LC2="%A, %d %B %Y %H:%M"
K2_DATE_FORMAT_LC="%A, %d %B %Y"
For the administrator lang files the path is /adminstrator/languages/....
Check your site using the system template (by using ?template=system as a URL suffix) to make sure that the template developer has not replace these default strings.
Please Log in or Create an account to join the conversation.
- Eugen
-
Topic Author
- Offline
- Senior Member
Less
More
- Posts: 40
10 years 8 months ago #131771
by Eugen
Replied by Eugen on topic Re: Display item creation date and year
You were right, it's a template issue, I'll be looking for a way to change that in template.
Thanks a lot for help!
Regards.
Closed.
Thanks a lot for help!
Regards.
Closed.
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
-
- Offline
- Platinum Member
Less
More
- Posts: 15920
10 years 8 months ago #131772
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Display item creation date and year
You 're welcome mate :)
Please Log in or Create an account to join the conversation.