styles.inc Set font color

Mar 25, 2015 at 1:55 PM
Maybe there are still people who read this forum, so I decided to give it a shot :)

Is there a way to set the font color according to the font color of the html in the styles.inc?
So if you had
...
<font color="0xff0000">Text</font>
...
and in styles.inc something like
...
'font color="xxxxxx"' => array (
        'color' => 'xxxxxx',
...
Would that be in some way possible?

Best Regards
Jul 22, 2015 at 6:22 AM
Yes you can do that . Following things you need to change in your code

Change this
...
<font color="0xff0000">Text</font>
...
to
...
<font style="color: FF0000">Text</font>
...
And in styles.inc instead of
...
'font color="xxxxxx"' => array (
        'color' => 'xxxxxx',
...
write this
 'color: FF0000' => array (
        'color' => 'FF0000',
   )
under
$styles['inline']
Jul 23, 2015 at 10:20 AM
Thank you very much for your reply.

But this way would still require to enter the colours statically, I was looking for a more general solution to 'forward' the color.

Best regards