1

No matter how I format my entry_date, it throws an error:

{exp:channel:calendar switch="calendarToday|calendarCell" channel="workshop_events" show_future_entries="yes" show_expired="yes"}
{calendar_rows}
{if entries}
    {entries}
        {title}<br />
        {entry_date format="%g:%i%a"}
    {/entries}
{/if}
{/calendar_rows}
{/exp:channel:calendar}

PHP error on the entry_date is as follows:

Undefined index: entry_date format="%g:%i%a"

Filename: channel/mod.channel_calendar.php

Line Number: 472

thanks for any advice.

2
  • output for the entry_date is the unformatted "1378055700"
    – P..
    Commented Sep 3, 2013 at 17:02
  • not enough reputation to answer my question right now. but found out that this is a bug in EE 2.7.0
    – P..
    Commented Sep 3, 2013 at 17:53

2 Answers 2

1

why not use :

{exp:channel:calendar switch="calendarToday|calendarCell" channel="workshop_events" show_future_entries="yes" show_expired="yes"}
{calendar_rows}
{if entries}
    {entries}
        {title}<br />
        {date format="%g:%i%a"}
    {/entries}
{/if}
{/calendar_rows}
{/exp:channel:calendar}
2
  • because I'm looking to display the entry_date, not the date.
    – P..
    Commented Sep 4, 2013 at 15:33
  • ah OK, I thought that within an entries tag pair {date} would output the entry date Commented Sep 4, 2013 at 15:42
1

Looks like a bug in EE 2.7.0 (thanks @solspace for pointing that out [offline]). meanwhile, I used PHP to solve this issue:

<?php echo date("g:i:a",{entry_date}); ?>

I also had to use date_default_timezone_set() because my server's settings were different than EE's general settings but it's working beautifully.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.