Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Try Vanilla Forums Cloud product

Ready to contribute?

Amazing! Sign our contributors' agreement and then join us on GitHub.

Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
Current version is 2.1.11, released 12 June.

Panel Categories

edited August 2006 in Vanilla 1.0 Help
This discussion is related to the Panel Categories addon.
Panel Categories

Comments

  • Any update on this extension-I cannot see half the categories in the list when I run this extension. Refreshing the page helped at first, but now the list has completely vanished. Any thoughts?
  • I have a patch to sort the categories alphabetically. It is attached at the bottom, hopefully it won't look horrid.

    @ithcy: I could send you the patch via email if you wanted to include it in the next release.

    41,43d40
    < $list = array();
    < $desc = array();
    < $curr = "";
    61,72c58,63
    < $list[$Row['Name']] = $thisURL;
    < $desc[$Row['Name']] = nicetrim($Row['Description'], $MaxDescriptionLength);
    < if ($CurrentCategory == $Row['CategoryID'])
    < {
    < $curr = $Row['Name'];
    < }
    < //$PanelCatNameVar = ($CurrentCategory == $Row['CategoryID'])? "PanelCatNameCurrent" : "PanelCatName";
    < //$PanelCategoryList .= "\t\t\t{$Row['Name']}\n";
    < //if ($ShowCatDescriptions)
    < //{
    < // $PanelCategoryList .= "\t\t\t" . nicetrim($Row['Description'], $MaxDescriptionLength) . "\n";
    < //}
    ---
    > $PanelCatNameVar = ($CurrentCategory == $Row['CategoryID'])? "PanelCatNameCurrent" : "PanelCatName";
    > $PanelCategoryList .= "\t\t\t{$Row['Name']}\n";
    > if ($ShowCatDescriptions)
    > {
    > $PanelCategoryList .= "\t\t\t" . nicetrim($Row['Description'], $MaxDescriptionLength) . "\n";
    > }
    75,85d65
    < ksort($list);
    < foreach ($list as $key => $value)
    < {
    < $PanelCatNameVar = ($key == $curr)? "PanelCatNameCurrent" : "PanelCatName";
    < $PanelCategoryList .= "\t\t\t{$key}\n";
    < if ($ShowCatDescriptions)
    < {
    < $PanelCategoryList .= "\t\t\t" . $desc[$key] . "\n";
    < }
    < }
    <
Sign In or Register to comment.