prophy
Mon 13 October 2008, 07:10 pm GMT +0200
I have the following problem:
I have a textarea with a basic CSS and a default text color but wat i need is to make one part of the content of this texarea in a different color. Realy i don't know is it possible. I need to do that "onLoad" of the textarea. It's like the WYSIWYG editors but i only need a part of the string to be in different color (nothing else /for now ;)/).
Thanks in advance.
Nikolas
Mon 13 October 2008, 09:34 pm GMT +0200
I am afraid you can't use a color for a part of a textarea but only for the whole textarea
olaf
Tue 14 October 2008, 10:14 am GMT +0200
you need to use tinymce or something
prophy
Tue 14 October 2008, 11:29 am GMT +0200
I am afraid you can't use a color for a part of a textarea but only for the whole textarea
I'm aware of that but WYSIWYG editors are able to do it (but as far as i know with some iframe).
I think that i can't use WYSIWYG editor for this becouse i need to color the string dinamicly :(. But i'll think of that option thanks Olaf.
olaf
Tue 14 October 2008, 08:52 pm GMT +0200
look tinymce or others are not showing you a textarea, they show you a box manipulated with JS. They use the textarea as an container which is able to post content
designer
Thu 23 October 2008, 04:38 pm GMT +0200
I think JS is what they used in this case...
jqueryHowto
Sat 18 April 2009, 01:24 pm GMT +0200
Get yourself a firebug and digg the html code with it. You might be able to see what textarea is being used at the background and what tags are being used to color some text. Then simply add those tags yourself.. and ask your wycwyg editor to refresh or something...
Working with text selects in javascript is a pain :)
timpane
Wed 13 July 2011, 06:46 pm GMT +0200
they display you a carton manipulated with JS. They use the textarea as an canister which is adept to mail content
Florinda
Wed 17 August 2011, 02:21 pm GMT +0200
i think u can do this using JavaScript..
netshet
Thu 18 August 2011, 11:34 am GMT +0200
you need to use tinymce or something