SimplePortal
Customization => Themes and Graphics => Topic started by: zushiba on January 20, 2010, 07:27:16 PM
-
Is there a simple way to add custom styles to the list of available styles for blocks?
Adding a Custom Body Class simply appends whatever you've got in the box to windowbgX that you've got selected.
-
No, there isn't a simple way as it would require template editing, source editing, and some conditional rewriting, as far as I'm aware.
You can fully customize blocks from the top to the bottom using those custom style options-- I managed it using a wide variety of CSS manipulating (see: backgrounds, margins, paddings, colors, offsets, etc)
-
You'll just need to add a single line to Themes/default/PortalAdminBlocks.template.php file.
<option value="windowbg3"', $context['SPortal']['block']['style']['body_default_class'] == 'windowbg3' ? ' selected="selected"' : '', '>windowbg3</option>
<option value="windowbg3"', $context['SPortal']['block']['style']['body_default_class'] == 'windowbg3' ? ' selected="selected"' : '', '>windowbg3</option>
<option value="classname"', $context['SPortal']['block']['style']['body_default_class'] == 'classname' ? ' selected="selected"' : '', '>classname</option>
Change the classname as the name of class you want to add to that list.
There is a reason why I call this thing flexible. ;)
-
Well it works and that's what's important. Thanks :)
-
Glad that it worked. ;)
-
thanks SiN, just what i was lo0king 4. =]
-
I guess manual hacking is certainly one way of doing it LOL.
-
I guess manual hacking is certainly one way of doing it LOL.
quite certainly the easiest. =D
-
I guess manual hacking is certainly one way of doing it LOL.
A single line won't hurt. ;)
You're welcome.