Textarea background - Solved!

alanvee - December 27, 2007 - 18:55
Project:FCKeditor - WYSIWYG HTML editor
Version:5.x-2.x-dev
Component:User interface
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed
Description

Greets!

I'm using FCK in a Drupal 5.5 site (http://www.sargasso-sea.net) with a theme (Golden_Hour) that has a very dark background. This is showing in the FCK textarea, and all attempts to adjust the various .css files cannot change it.

The background in the FCK textarea box IS coming from the theme. Any clues how I can over-ride this? The FCK CSS defines 'body' but for some reason I can't get this to over-ride the theme body def.

FCK is functional but it is very difficult to read black text on a dark background. LOL!

=Alan R.

#1

jadwigo - December 27, 2007 - 22:22
Status:active» by design

make a copy of the themes css and change the text colors accordingly, use that css as the custom css in your config.

#2

HenrikWL - December 28, 2007 - 11:53

Another solution is to attach the background to a wrapper <div> instead. This way you don't have to have two different stylesheets. I don't know how FCKEditor displays its HTML, but it's bound to have a body element, so any styling you do to your body element also gets reflected in the FCKEditor.

#3

alanvee - December 29, 2007 - 01:26
Title:Textarea background» Textarea background - Solved!
Status:by design» closed

Thanks, jadwigo and HenrikWL, but the REAL answer is:

(I found this in the FCK developers Wiki) In the fckconfig.js file is a parameter named "FCKConfig.BodyId=''; I added an additional style in the theme CSS called #fckback, and set it to the color I wanted. Then I changed the param to "FCKConfig.BodyId='fckback';

After a cache-clear -- volia! The correct textarea color appeared!

=Alan R.

#4

jandoemen - January 3, 2008 - 00:26

Alanvee, your the best. Works great!!!

Thanks a lot.
Jan

#5

elmofromok - January 3, 2008 - 14:34

There is also a setting in the FCKEditor config page to use the fck default instead of the theme css, this will correct this problem and use a white background.

#6

romunov - February 17, 2008 - 12:59

elmofromok's solution worked for me.

#7

tomdisher - February 28, 2008 - 19:56

I registered just to make a post to thank you. I sorted through every single css file in the fck folder and couldn't figure this out.

#8

wadley0 - April 29, 2008 - 17:09

Note: alanvee's solution can be implemented from within drupal.

Administer > Site configuration > FCKeditor

[profile] edit > Advanced options

paste the code into the 'Custom javascript configuration:' section.

FCKConfig.BodyId='fckback';

then add your css for fckback.

#9

mrtasteit - July 2, 2008 - 22:39

hi all - new to this, and neither alanvee's nor wadley0's suggestions are working for me. it basically "whited-out" my entire fck editor.

Is this the correct css:

#fckback {
background-color:#ffffff;
}

or even this:

#fckback {
background:#ffffff;
}

I will now try elmofromok's solution...

thanks

#10

mrtasteit - July 2, 2008 - 22:47

elmofromok's solution was painlessly easy - i appreciate everyone's efforts though. getting my hands dirty through making mistakes is the best way to learn!

#11

Goosemoose - September 7, 2008 - 00:46

alanvee method works great, thanks. I'm hosting multiple sites with many themes so this method is much cleaner.

wadley0, I couldn't find an advanced option so I just edited the file manually.

 
 

Drupal is a registered trademark of Dries Buytaert.