469,936 Members | 2,444 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,936 developers. It's quick & easy.

Javascript to add tags to a text area on a form?

Does anyone know a simple Javascript to add tags to a text area on a form.

On clicking a bold button for instance <strong></strong>

?

Any help appreciated, thanks,
kate
Jul 20 '05 #1
3 1673
katherine wrote:
Does anyone know a simple Javascript to add tags to a text area on a form.
On clicking a bold button for instance <strong></strong>


To do that, you'd use ranges, under the risk of getting malformed HTML
in the end; we've discussed this issue with Richard some time ago, you
might find the following thread useful (URL wrapped):

<URL>
http://groups.google.com/groups?hl=e...8&frame=right&
th=57d63b74cc1d5495&seekm=d2d855ea.0301211618.1a09 2cdd%40postin
g.google.com#link11
</URL>
HTH
Yep.
Jul 20 '05 #2
Thanks very much Yep.

I have gone through the correspondance with Richard which was really
helpful.

I can't get the script to work with IE 5+ on a Mac though which is my
main objective.

Any ideas anyone??

Thanks very much,

K
Jul 20 '05 #3
Yann-Erwan Perio wrote:
[...] (URL wrapped):

<URL>
http://groups.google.com/groups?hl=e...8&frame=right&
th=57d63b74cc1d5495&seekm=d2d855ea.0301211618.1a09 2cdd%40postin
g.google.com#link11
</URL>


Please do not do this. Fortunately Mozilla/5.0 MailNews does not have
the OE bug that even URLs are wrapped, so do not try to impose that on
it. Leave them as they are and they stay functional hyperlinks in most
newsreaders.
PointedEars
Jul 20 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Mike Walker | last post: by
7 posts views Thread by Trvl Orm | last post: by
15 posts views Thread by binnyva | last post: by
24 posts views Thread by firstcustomer | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.