Forum

Thread tagged as: Question, Addons

Event App 1.9 Calendar View Order by DateTime

Running into a time sort issue on perch_events_calendar view where events aren't sorted by time correctly. They are sorted by date properly.

Could this be a server issue? (I seem to recall in the old forums something about the default time on the server may cause a sorting issue.)

Can we use sort and sort order with perch_events_calendar like we can with perch_events_custom?

I tried but that didn't seem to make a change.

We're running Perch_Events 1.9 on Perch 2.7.3.

Scott Gruber

Scott Gruber 0 points

  • 7 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Which locale is your server set to?

When I check my server clock at /etc/sysconfig/clock

I get back

ZONE="America/Los_Angeles"

In /perch/config/config.php I have listed

define('PERCH_TZ', 'America/Los_Angeles');

Should it make any difference if the hardware clock on the server is on UTC time?

Drew McLellan

Drew McLellan 2638 points
Perch Support

The clock makes no difference.

Which locale is your server set to?

I also have this problem, events in the calendar are showing in the wrong order.

setlocale returns 'C', is that an issue?

When I run locale on the server, I get back --

LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=
Drew McLellan

Drew McLellan 2638 points
Perch Support

Ok, that looks good. I don't have a quick fix to suggest, but I'm working on it.