HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


How time is show?

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#43138 (In Topic #9592)

Non-joined user

I have look every where in admin Zone after to change time from 12h to 24h show. Is possible to do that?
included forum & portal.



:$
Best Regards Christian
Back to the top
 
Posted
Rating:
#43146
Avatar

Community saint

Have a look in /lang/EN/global.ini under [strings]. You should find a whole bunch of date/time settings. Probably best to save the original just in case you don't get it quite right …

 :thumbs:

Take my advice. I'm not using it!

View my working ocPortal site (version 9.x.x) at Anglo-Indian Portal
Back to the top
 
Posted
Rating:
#43189
Avatar

Fan in action

I try to change
#time_hour_and_mins=h:i a
time_hour_and_mins=H:i


(H) but it seams not work, is there more place to change in?

Regards Christian

Fletch said

Have a look in /lang/EN/global.ini under [strings]. You should find a whole bunch of date/time settings. Probably best to save the original just in case you don't get it quite right …

 :thumbs:
Back to the top
 
Posted
Rating:
#43195
Avatar

In this chunk of the file:

Code

date_withinday=%i:%M
date_withinweek_date=%a
date_withinweek_joiner=
date_withinweek_time=%M%p
date_regular_date=%d %B %Y
date_regular_joiner=,
date_regular_time=%i:%M %p
date_verbose_date=%a %d %B %Y
date_verbose_joiner=,
date_verbose_time=%i:%M %p

All the %i stuff refers to a 12 hour clock hour.
For a full list of options see:
PHP: strftime - Manual

You probably want to change %i to %H and remove " %p".

Rather than editing the .ini file directly, I'd recommend you do it through ocPortal.
Look under: Admin Zone > Style Section > Language icon

I recommend that because it will automatically clear the language cache and save your changes as an override file (so they won't get lost when you upgrade).


Become a fan of Composr on Facebook or add me as a friend. Add me on on Twitter. Support me on Patreon
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#43243
Avatar

Fan in action

It's work like charm!! Thanks for our help!

/Best regrades Christian

Chris Graham said

In this chunk of the file:

Code

date_withinday=%i:%M
date_withinweek_date=%a
date_withinweek_joiner=
date_withinweek_time=%M%p
date_regular_date=%d %B %Y
date_regular_joiner=,
date_regular_time=%i:%M %p
date_verbose_date=%a %d %B %Y
date_verbose_joiner=,
date_verbose_time=%i:%M %p

All the %i stuff refers to a 12 hour clock hour.
For a full list of options see:
PHP: strftime - Manual

You probably want to change %i to %H and remove " %p".

Rather than editing the .ini file directly, I'd recommend you do it through ocPortal.
Look under: Admin Zone > Style Section > Language icon

I recommend that because it will automatically clear the language cache and save your changes as an override file (so they won't get lost when you upgrade).
Back to the top
 
There are too many online users to list.
Control functions:

Quick reply   Contract

Your name:
Your message: