Joined: Jun 03, 2004 Posts: 229 Location: Tamworth, UK
Posted:
Tue Jan 19, 2010 4:28 pm
Quick (ish) one guys;
I'm trying to modify a theme; I've managed to change all the various colours EXCEPT one set;
the expanding/ collapsing forums block (center)- I can't seem to work out which attribute it is I need to change for the font colour in the top of the table
([Forum] Topic Replies Author Views Last Post )
These are in bold.
If someone could please advise which css fill (theme or forums within the theme folder) and which particular part (style) it would be much appreciated.
I can provide a link to the dev server if required.
Joined: Jun 03, 2004 Posts: 229 Location: Tamworth, UK
Posted:
Thu Jan 21, 2010 4:06 am
thanks, Raven. I'm guessing (if it is) it's just a matter of tweaking the code to pick up the css? (I'm guessing one of the fields from the forum css?)
I'll see if I can get access to the block code from work, and take a look
if (file_exists('themes/'.$ThemeSel.'/modules/'.$name.'/'.$mod_file.'.php')) {
$modpath = 'themes/'.$ThemeSel.'/';
But I notice the font colour is the same for any theme, so guessed it's possibly not defined? As it turned out, that wasn't the case; the theme I'm "playing" with has had some issues (I managed to sort most of them by looking into the relevant files- nothing major- posting to wrong directories for images, etc.)
I then opened up theme/theme.php
I found the following:
I figured I'd change the hex value (in my case for that block, $textcolor1) and it worked....
My question is (and it *may* be fairly simple for some one with more experience)
Is it possible to change either the reference in the forum collapsing block to pick up a particular field from the css file? (either the one for the forum, OR the one for the site)
And/ or do the same to the theme.php file? Maybe define somewhere in one of the main config files/ where the theme is defined in the DB that $color1,2,etc and bgcolor1,2 etc. are a particular field in the site's theme css file?
Just a thought. Sorry if I'm being a pain- figure if as much as possible is in one configuration file for the theme (css?) then it makes it easier for all blocks, whether used or not to pick up the theme....
Joined: Dec 02, 2006 Posts: 1364 Location: Texas, USA
Posted:
Thu Jan 21, 2010 7:08 am
You can certainly edit the block to use whatever css classes you wish, but alot of modules use the $bgcolor1, $bgcolor2, $bgcolor3 and $bgcolor4 values so it wouldn't be easy to replace them globally. When this variable is used a hex value is expected, and you would end up with errors if you tried to replace it with a class... here is just one example from the content module:
Joined: Jun 03, 2004 Posts: 229 Location: Tamworth, UK
Posted:
Thu Jan 21, 2010 7:48 am
could you not use a configuration file (xml?) that substituted the variable for an equivalent declaration in the .css?
That way, no matter which theme any one was using/ if it changed, the colours would alter accordingly. (Not sure if I'm explaining myself here)
I think what I'm trying to say, is, instead of something being hard coded into a block/ module, the config file is used, thus saving any colour "mis-match" like I've just experienced. (Or does it do that already, and I've got it all wrapped around my tits)
View next topic View previous topic
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum