change the Events Pro widget display date

Home Forums Calendar Products Events Calendar PRO change the Events Pro widget display date

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #987705
    flyingarts
    Participant

    Hi Folks – I’m using the Calendar Pro events widget in the sidebar and in other widget areas.
    Currently the widget thumbnail date on the left shows the day of the week and then the date underneath.
    See the bottom widget in my sidebar here
    http://flyingarts.pboworkspace.info/news/

    Is there anyway to set it as is shows the Month and the day and date underneath?
    See my mockup here

    Screen Shot 2015 07 20 at 11 54 40 am

    This would make far more sense in the list view

    cheers

    #987865
    Geoff
    Member

    Hi Stephen!

    Sure, that is quite possible. Here’s how to change the widget from showing the day of the week to showing the abbreviated month instead:

    • Make a copy of the widget template. It is located in /plugins/the-events-calendar/widgets/modules/single-event.php
    • Make a new folder in your theme directory called tribe-events
    • Make a new folder in that one called widgets
    • Make a new folder in that one called modules
    • Drop the copied template in that last folder

    Now that the template is in your theme, it can be customized to suit your needs. In this case, change this line:

    [php]
    <span
    class="list-dayname"><?php echo apply_filters( ‘tribe-mini_helper_tribe_events_ajax_list_dayname’, date_i18n( ‘D’, $postDate ), $postDate, $mini_cal_event_atts[‘class’] ); ?></span>
    [/php]

    …to this:

    [php]
    <span
    class="list-dayname"><?php echo apply_filters( ‘tribe-mini_helper_tribe_events_ajax_list_dayname’, date_i18n( ‘M’, $postDate ), $postDate, $mini_cal_event_atts[‘class’] ); ?></span>
    [/php]

    Does this work for you? Please let me know. 🙂

    Cheers!
    Geoff

    #988201
    flyingarts
    Participant

    awesome thanks Geoff – will check it out and see

    #988204
    flyingarts
    Participant

    Also Geoff, another quick question – using your logic above , is it possible to show the featured image thumbnail instead of the date?

    #988381
    Geoff
    Member

    Absolutely! You can modify the template to suit any of your needs now that it is in your theme directory. Plus, this way, your customizations will stay in tact, even after an update to the plugin. 🙂

    Keep me posted and let me know if the date format worked out for you.

    Geoff

    #993371
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘change the Events Pro widget display date’ is closed to new replies.