-
how to change text color in text area-javascript
I am having a color picker which gives a color code , i have to change the color of text/font in textarea according to color code generated dynamically.... i am unable to use color code to change the text color plz help
-
Hello druveen,
You might need to post some of your code to make sense.
But, something like this should work:
<input type="hidden" id="chosenColour" value="#ABCDEF" />
<div onclick="document.getElementById('changeMe').style.color=document.getElementById('chosenColour').val ue;">Change the colour</div>
<div id="changeMe">I will change colour!</div>
Of course you need to integrate that with your colour picker but hopefully you get the idea.
(Sorry for the *correct* spelling of colour for all you US folks )
Regards,
David
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules