File: plugins/content_types/term_context/term_list.inc
Function: ctools_term_list_content_type_render()

theme_item_list() uses the array keys to determine when to add the classes 'first' & 'last'. Since the $items passed are using the term id as keys, the class attributes are being applied incorrectly. You could override the theme function to fix, but doesn't seem like these keys are being used.

Example:

Array
(
    [5]  => Term1	<-- this doesn't get the class 'first'
    [10] => Term2
    [4]  => Term3
    [9]  => Term4
    [3]  => Term5
    [6]  => Term6	<-- this gets the class 'last'
    [8]  => Term7
)

Line 54:

$items[$related->tid] = l($related->name, taxonomy_term_path($related), array('rel' => 'tag', 'title' => strip_tags($related->description)));

Fix (remove key):

$items[] = l($related->name, taxonomy_term_path($related), array('rel' => 'tag', 'title' => strip_tags($related->description)));

Comments

merlinofchaos’s picture

Status: Active » Fixed

Silly theme('item_list') making assumptions about keys.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.