Totally Zenned
- Join Date:
- May 2009
- Posts:
- 1,273
- Plugin Contributions:
- 3
extracting the first category from array
Hi
Working on 1.55e in local.
I would need to append a class to the first item of category array list in modules/category_row.php which then I am going to use in templates/CUSTOM/common/tpl_columnar_display.php
I guess is the following (in case it's somewhere else please advise)
$list_box_contents[$row][$col] = array('params' => 'id="category' . $categories->fields['categories_id'] . '" class="categoryListBoxContents"',
'text' => '<a href="' . zen_href_link(FILENAME_DEFAULT, $cPath_new) . '">' . zen_image(DIR_WS_IMAGES . $categories->fields['categories_image'], $categories->fields['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '<br />' . $categories->fields['categories_name'] . '</a>');
but don't know how to do so.
I am aware of the id for the styling purpose, but need to add a class.
Thank you