Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Franky

    (@liedekef)

    I added a new conditional tags in trunk (dev version) to check for all day events, so you can change the layout then.
    See: https://plugins.trac.www.ads-software.com/changeset/838505

    Thread Starter oyegigi

    (@oyegigi)

    So how does one actually implement this feature?

    Thread Starter oyegigi

    (@oyegigi)

    OK. I figured it out and thought I would post what I came up with in case someone else was needing help on the same issue.

    Unfortunately the site isn’t live quite yet, but in hopes this can be of use to someone in the future: https://www.glenisredmond.com/tour-dates/

    I wanted to accomplish 2 different things:

    • On my event list format I wanted to make notes if an event was an all day event or multi-day event.
    • On my single event format I wanted to show only the start date if it was a single date event, show both start and end dates if it was a multi-day event, and replace the dates with “all day” if it was an all day event.

    EVENT LIST:
    (this code is stripped down to the essentials. You’ll have to style it appropriately)

    [events_if tag='#_IS_ALLDAY' is_empty=0]This is an all day event. [/events_if]
    [events_if tag='#_IS_ALLDAY' is_empty=1]Event starts at #_{g:ia}. [/events_if]
    [events_if tag="#ESC_{j M Y}" notvalue="#ESC@_{j M Y}"] This is a multi-day event. [/events_if]

    SINGLE EVENT:

    [events_if tag="#ESCj #ESCM #ESCY" value="#ESC@j #ESC@M #ESC@Y"]#M #j #Y[/events_if]
    [events_if tag="#ESCj #ESCM #ESCY" notvalue="#ESC@j #ESC@M #ESC@Y"]#M #j -<br />#@M #@j[/events_if]
    [events_if tag='#_IS_ALLDAY' is_empty=0]ALL DAY[/events_if]
    [events_if tag='#_IS_ALLDAY' is_empty=1]#g:#i#_{a}[/events_if]
    Plugin Author Franky

    (@liedekef)

    ‘is_empty’ should be ‘value’, for better readability.
    And the first line for single event code could also be:

    [events_if tag="#ESC_{j M Y}" value="#ESC@_{j M Y}"]#M #j #Y[/events_if]

    Idem for the second line (like you did for the event list btw).

    Also: I added #_IS_MULTIDAY to the conditionals in trunk as well ??

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Output "all day" rather than 12AM’ is closed to new replies.