Categories collapsed, by default?

Started by birchy, February 20, 2011, 12:53:53 AM

Previous topic - Next topic

birchy

Any way to force the categories to default to collapsed in the Board Index? I have almost 100 categories.

birchy

(Subs-BoardIndex.php, about line54)

   $hackStr = $user_info['is_guest'] ? '1 AS is_collapsed,' : 'IFNULL(cc.id_member, 0) AS is_collapsed,' ;
   $result_boards = $smcFunc['db_query']('boardindex_fetch_boards', '
      SELECT' . ($boardIndexOptions['include_categories'] ? '
         c.id_cat, c.name AS cat_name,' : '') . '
         b.id_board, b.name AS board_name, b.description,
         CASE WHEN b.redirect != {string:blank_string} THEN 1 ELSE 0 END AS is_redirect,
         b.num_posts, b.num_topics, b.unapproved_posts, b.unapproved_topics, b.id_parent,
         IFNULL(m.poster_time, 0) AS poster_time, IFNULL(mem.member_name, m.poster_name) AS poster_name,
         m.subject, m.id_topic, IFNULL(mem.real_name, m.poster_name) AS real_name,
         ' . ($user_info['is_guest'] ? ' 1 AS is_read, 0 AS new_from,' : '
         (IFNULL(lb.id_msg, 0) >= b.id_msg_updated) AS is_read, IFNULL(lb.id_msg, -1) + 1 AS new_from,' . ($boardIndexOptions['include_categories'] ? '
         c.can_collapse, '.$hackStr : '')) . '
         IFNULL(mem.id_member, 0) AS id_member, m.id_msg,
         IFNULL(mods_mem.id_member, 0) AS id_moderator, mods_mem.real_name AS mod_real_name


First bold item is new code, second is replaced code.

Advertisement: