Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CSS question

Status
Not open for further replies.

PhoenixDown

Programmer
Jul 2, 2001
279
CA
Can someone please tell me how I can use CSS in a textarea to change the color of ONE word? Thanks! ;-) AIM: XCalvin1984
Email: calvin@puremadnezz.com
MSN: xcloud2000x@hotmail.com
Web Site: Yahoo Messenger: xcloud2000x

Contact me for any programming help and whatnot. I'll try my best to help! :)
 
<span style=&quot;color:red;font-weight:bold&quot;>Changed Words</span> DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
It doesn't work. Here's what the code shows up as when I view source:

Code:
<textarea name=&quot;NonCGIFilesDisplay&quot; rows=&quot;15&quot; cols=&quot;90&quot; wrap=&quot;virtual&quot;>...
<span style=&quot;color:red;font-weight:bold&quot;>/home/puremadnezz/misc/gb/aim.gif - Completed!</span>
...</textarea>

Am I doing it right? :-( AIM: XCalvin1984
Email: calvin@puremadnezz.com
MSN: xcloud2000x@hotmail.com
Web Site: Yahoo Messenger: xcloud2000x

Contact me for any programming help and whatnot. I'll try my best to help! :)
 
You can't change individual parts of a textarea different colors. Sounds like you really want an ActiveX Control (RichTextBox or Browser Control) - or perhaps better for your purposes an <IFRAME>?

Depends on what you're doing - displaying text or accpeting form input (normal use for textareas).

'Course Netscrape will have a fit.
 
Thanks anyways, but I've decided not to continue making what I was. It wasn't working correctly. Web site: Email: calvin@puremadnezz.com
AIM: XCalvin1984
MSN: xcloud2000x@hotmail.com
ICQ: 135616065 (I don't really use ICQ alot.)
Yahoo Messenger: xcloud2000x (I don't really use Yahoo messenger alot.)

Contact me for any programming help and whatnot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top