News:

Wondering if this will always be free?  See why free is better.

Main Menu

Theme Colors - Change on a board level

Started by hawk11220, September 12, 2015, 06:42:25 PM

Previous topic - Next topic

DanielSan34

Quote from: Antechinus on September 12, 2015, 07:35:35 PM
What these will do is set a body tag id according to the board you are in.  You can then use that for CSS targetting on a per-board basis.
hello,

i'm looking for the same result but with this issu
instead of
$context['current_board']
this is possible to generate the id of the parent-forum (or category) ?

looking the linktree array in $context, i would like to use #c45
[linktree] => Array
        (
            [0] => Array
                (
                    [url] => http://localhost/forum/index.php?action=forum
                    [name] => general name
                )

            [1] => Array
                (
                    [url] => http://localhost/forum/index.php?action=forum#c45
                    [name] => forum/category name
                )

            [2] => Array
                (
                    [url] => http://localhost/forum/index.php?board=173.0
                    [name] => topic name

        )


searching in /sources/load.php :

// Build up the linktree.
$context['linktree'] = array_merge(
$context['linktree'],
array(array(
'url' => $scripturl . '#c' . $board_info['cat']['id'],
'name' => $board_info['cat']['name']
)),
array_reverse($board_info['parent_boards']),
array(array(
'url' => $scripturl . '?board=' . $board . '.0',
'name' => $board_info['name']
))
);

it's $board_info['cat']['id'] that i would use for my id body in board and topic theme.

How can i do this ?

thanks you

ps : i'hope my "english" would understanding ;D

Advertisement: