Cant display dates in an archive
-
HI
I’ve build a custom layout for my event archive (archive-event.php)
When I try to call
<?php echo $EM_Event->output('#_EVENTDATES'); ?>I get the errorFatal error: Call to a member function output() on null in TEMPLATEURL/archive-event.php on line 36line 36 is the line that calls the above code
Here’s the code
<?php if(have_posts()) : while(have_posts()) : the_post(); ?> <div class="column one-third l-one-half s-one-whole"> <div class="event"> <div class="event-image"> <a href="<?php the_permalink(); ?>"><?php get_the_image(array('size' => 'event_square')); ?></a> </div> <div class="event-text"> <a href="<?php the_permalink(); ?>"> <h3 class="event-title"> <?php the_title(); ?> </h3> <p class="event-meta"> <?php echo $EM_Event->output('#_EVENTDATES'); ?></p> <span class="event-more"> <?php the_excerpt(); ?> </span> </a> </div> </div> </div> <?php endwhile; else : ?> <div class="column one-whole center"> <p>No upcoming events...</p> </div> <?php endif; ?>Any thoughts?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘Cant display dates in an archive’ is closed to new replies.