WordPress.org

Ready to get started?Download WordPress

Forums

Events Manager
Calendar items not arranged chronologically (5 posts)

  1. fanatical_g
    Member
    Posted 2 years ago #

    Hey there,

    I've noticed that the items I put in are arranged in the order I put them in, and not chronologically. Is there a way to fix this?

    Thanks!

    http://wordpress.org/extend/plugins/events-manager/

  2. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 2 years ago #

    i believe if you have the right order set in the page for the default events list (settings page) the shortcode supports the order attribute (see site documentation)

  3. olyma
    Member
    Posted 2 years ago #

    I think I may have also experienced this issue, too. I'm using an older version (3.0.95).

    The settings page for ordering of events only appears to be for controlling the "Events" page, and not the "Calendar" page. The issue is, as said above by fanatical_g, the events in each day-box are listed in the order that they were entered, and not in the chronological order that they are actually going to occur throughout their given day. I've been digging through the code all night tonight to find a solution and here's what worked for me:

    In the "classes" directory, find the file "em-calendar.php" and right after $long_events = $args['long_events']; (approximately at line 16 in v. 3.0.95) insert the following code and save the file:

    $args = array(
    'orderby' => 'start_date,start_time,name',
    'order' => 'ASC',
    );

    At least this worked for me.

    Wellest wishes!

  4. olyma
    Member
    Posted 2 years ago #

    Actually, the code above is having some ill repercussions elsewhere, I'll check back later as I continue get it ironed out.

  5. olyma
    Member
    Posted 2 years ago #

    Later....

    Okay the code above should instead be:

    $full = $args = array(
    'orderby' => 'start_date,start_time,name',
    'order' => 'ASC',
    );

    And that makes all of the "Calendar" pages work now. :D

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic