Skip to content

Commit

Permalink
Add a category's css class to its item. Closes #1557.
Browse files Browse the repository at this point in the history
  • Loading branch information
tburry committed Apr 13, 2013
1 parent ed6f1b5 commit cdfd768
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions library/core/functions.render.php
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,8 @@ function CssClass($Row, $InList = TRUE) {
// Category list classes
if (array_key_exists('UrlCode', $Row))
$CssClass .= ' Category-'.Gdn_Format::AlphaNumeric($Row['UrlCode']);
if (GetValue('CssClass', $Row))
$CssClass .= ' Item-'.$Row['CssClass'];

if (array_key_exists('Depth', $Row))
$CssClass .= " Depth{$Row['Depth']} Depth-{$Row['Depth']}";
Expand Down

0 comments on commit cdfd768

Please sign in to comment.