/    Sign up×
Community /Pin to ProfileBookmark

Highlight text into textarea

Hola boys, i’ve a question for you!
It’s possible to highlight some text inside a textarea? (not all text, but a portion!)
For example, i’ve this text inside a textarea.

[ B ] INSERISCI TESTO [ /B ]

i want to highlight only “INSERISCI TESTO”.
It, must be an universal function, so i can use it also in other cases, for example when tag are [ SM ] and [ /SM].
I hope someone can help me, because through internet i find only code IE compatible e not FIREFOX compatible, and viceversa.
I’d like to have compatibility with both browser.

Thank you so much, for your help.
I’m waiting for you…

tranky

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@phpnoviceMay 16.2006 — IE-compatible code is all I would have to offer you, too. The problem is that good documentation on anything except IE is almost non-existent. Other browser manufacturers could learn a thing or two from MicroSoft.
×

Success!

Help @tranky spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.27,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...