# HG changeset patch # User Dan # Date 1242518159 0 # Node ID 125e913485a2b01bac5c812114b9c9982c3f9cd2 # Parent eaeb479c52c9eee4b2a6c575f4993ef7e6c0293f Updated for Enano 1.1.6. diff -r eaeb479c52c9 -r 125e913485a2 plugins/CategoryList.php --- a/plugins/CategoryList.php Fri Aug 15 20:39:02 2008 -0400 +++ b/plugins/CategoryList.php Sat May 16 23:55:59 2009 +0000 @@ -9,14 +9,14 @@ */ // attach parser hook -$plugins->attachHook('render_wikiformat_pre', 'catlist_parser_hook($text);'); +$plugins->attachHook('render_wikiformat_veryearly', 'catlist_parser_hook($text);'); function catlist_parser_hook(&$text) { if ( preg_match_all('/\{\{ - Category: + CategoryContents: ([^|\r\n\a\t]+?) # category name - (\|(?:(?:[a-z0-9_]+)(?:[\s]*)=(?:[\s]*)(?:[^\}\r\n\a\t]+))) # parameters + (\|(?:(?:[a-z0-9_]+)(?:[\s]*)=(?:[\s]*)(?:[^\}\r\n\a\t]+)))? # parameters \}\}/x', $text, $matches) ) { foreach ( $matches[0] as $i => $match ) @@ -106,7 +106,7 @@ $ticker = 0; $have_subcats = false; $class = 'row1'; - while ( $row = $db->fetchrow() ) + while ( $row = $db->fetchrow($q) ) { if ( empty($row['is_subcategory']) ) break;