Hey there.
I would like to know if it's possible to change the color of the border for one category only. For example: default category for public with default colors and admin category for admins with different colors. Both of them visible on one page when admin is logged in.
If it is possible, how do I start?
1. Add '.admintable' to style.css with colors I like
2. Assign what table from where to use '.admintable' style?
I have 1.0.7.
Open up your BoardIndex.template.php file and search for:
<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="5">
And replace it with this:
<div class="';
if ($category['id'] === '1')
{
echo 'adminclass';
}
else
{
echo 'tborder';
}
echo '"><table border="0" width="100%" cellspacing="1" cellpadding="5">
The category id defined here is the category that you want the class assigned to ;)
Thanks for your reply, again :)
I guess the category id defined in your code won't be replaced by the category's name because I couldn't get it to work?
I replaced the code and here's what I wrote on style.css Did I get it right?
.adminclass
{
background-color: #ffffff;
border: 1px solid #ff0000;
}
You might also want to add some padding like "padding: 2px;" to the stylesheet to make the border more noticable. You of course can use the category name but I had thought the using the id would be easier to manage. To use a category name modify the variable like this: "$category['name']" ;)
Thank you :)