I have a website that will have events and game dates for roller derby teams across the nation (
http://www.derbynation.net).. The Upcoming Events Block only shows the event title. I want it to also show the league name or the state.
How can I modify the Upcoming Events Block and the Event List View to include a CCK field for the league name (field_league_nm)?
I also want to modify the Event List View to include the league name (field_league_nm) and the state (field_event_state).
Any help is greatly appreciated. I tried modifying the event.module file to say:
function theme_event_upcoming_item($node, $types = array()) {
$output = l($node->title, "node/$node->nid", array('attributes' => array('title' => $node->title)));
if (count($types) > 1) {
$output .= '<span class="event-nodetype">('. $node->event['node_type'] .')</span>';
}
//Added this line below to try and call the CCK field, league name. It does not work.
$output .= '<br><span class="event-custom">'. $node->field_league_nm[0]['safe'] .'</span>';
$output .= '<span class="event-timeleft">'. event_format_date($node->event_start, 'custom', "D M j @ G:ia").'</span>';
return $output;
}This doesnt work. How can I call the CCK field from event.module? I am pretty new to drupal and to php.. so I need a little guidance. If I can just get the correct reference to point to, I think I can get this to work.
Thanks!
Sumati