If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

I want to change the color of that text from black to white, but that rgb(0, 0, 0) doesnt let me do it with CSS and i cant just take it off since its generated by some cryptic javascript code i cant figure out so i guess the only way is to write another javascript that overrides the color:rgb(0, 0, 0) property and make it white but im not sure on how to do it. Can you give me some ideas?

In rgb notation, white is rgb(255, 255, 255) which, I think, can be abbreviated to rgb(255). The strange thing about your example is that the div does not have an ID. I have no idea how the color could be changed in JS without an ID. Are you sure that it is correct?

It has nothing to do with the rgb assignation, but rather that inline styles will override css declatations.

There are a couple of ways around it, but the simplest (if you want all divs with the class name gwt-HTML to have white text) is to put this at the end of your body section, just before the </body> tag:

Thanks. Actually not all of them, only the ones with rgb(0) because the background is dark, so text wont be readable in black. Also, its a chat and content is generated in real time, so i need the code to change the color dynamically everything a message appears. I wonder if thats possible.

exactly right before the </body> tag? because seems like it wont let me put it there. The parsed code shows some bits of code after whatever i put before the </body> tag. I wonder if i can put it somewhere else such as within the head tag.

The problem is that i cant put it right before the </body> tag because the full code is very complex and its fully generated by javascript so i cant tell what to modify in order to get it show right there. I can put it inside head or after the <body> tag though. I will send you the link to my page by PM for security reasons. Thank you for your help.

aaaah. I get it now. This is the problem: your page creates divs, and the code I gave you will only work on divs that have already been created. I think really your best option is editing the css - if you can't do that, you would have to look for some sort of listener that tells you when a new div has been added and run the code then.

I see. That sounds terribly complicated. The source code is a real pain in the ass. I've located the piece of code that adds the rgb property to the div. Its this:

p=b.c;

terribly simple, huh? if i take it off then that rgb thing disappears from the div. However, now you wont be able to change your font color. I wish i could trace the function that does all this and just set white as the default color but this level of code is too much for me.