Cannot control format of Single Category
-
I’ve been trying to get a single events category page to work and nomatter what code I put in Events > Settings > Formatting > Event Categories I cannot get anything to work.
1.) I tried putting this code in “Single Category Format”
<h1>#_CATEGORYNAME</h1>
‘<table cellpadding=”0″ cellspacing=”0″ class=”events-table” width=”100%” align=”center”>
<thead>
<tr>
<th class=”event-time” width=”20%”>Date</th>
<th class=”event-description” width=”40%”>Tour</th>
<th class=”event-price” width=”20%”>Price</th>
<th class=”event-booking” width=”20%”>Book Now</th>
</tr>
</thead>
<tbody>
<tr>
<td class=”event-time” width=”20%”>#_EVENTDATES </td>
<td class=”event-description” width=”40%”>#_EVENTLINK</td>
<td class=”event-price” width=”20%”>$#_ATT{Price}</td>
<td class=”event-booking” width=”20%”>Book Now </td>
</tr>
<tbody>
</table>’2.) I tried putting the same code in “Default events list format”
3.) I tried to create single-category.php template using this code:
‘<?php get_header(); ?>
<div id=”content” class=”grid_12″>
<div id=”content” role=”main”>
<?php
global $post;
$EM_Event = em_get_event($post->ID, ‘post_id’);
?>
<header class=”entry-header”>
<h1 class=”entry-title”><?php echo $EM_Event->output(‘#_EVENTNAME’); ?></h1>
</header><div class=”entry-content”>
<table cellpadding=”0″ cellspacing=”0″ class=”events-table” width=”100%” align=”center”>
<thead>
<tr>
<th class=”event-time” width=”20%”>Date</th>
<th class=”event-description” width=”40%”>Tour</th>
<th class=”event-price” width=”20%”>Price</th>
<th class=”event-booking” width=”20%”>Book Now</th>
</tr>
</thead>
<tbody>
<tr>
<td class=”event-time” width=”20%”><?php echo $EM_Event->output(‘#_EVENTDATES’); ?></td>
<td class=”event-description” width=”40%”><?php echo $EM_Event->output(‘#_EVENTLINK’); ?></td>
<td class=”event-price” width=”20%”><?php echo $EM_Event->output(‘$#_ATT{Price}’); ?></td>
<td class=”event-booking” width=”20%”>Book Now </td>
</tr>
<tbody>
</table>
</div>
</div><!– #content –>
</div><!– End container_12 –>
<?php get_footer(); ?>’What is happening is that I am getting a list from my events page.
Here’s the events page: https://fsguides.com/events/
Here’s the Category page: https://fsguides.com/reserve-a-trip/categories/
Here’s a single Category page: https://fsguides.com/trips/categories/grand-canyon/
If there are multiple events in one category, I am not sure how to list them. The Category details provided do not do it.
In addition when you look at a single Categories page (i.e. https://fsguides.com/trips/categories/grand-canyon/) there’s no classes (from the events page) so I cannot even edit what shows up on this page with css. Any help would be appreciated.
- The topic ‘Cannot control format of Single Category’ is closed to new replies.