skip to Main Content

Can Javascript replace text not in a tag?

I have a string with bbcode in it: "[area=A]A[/area] very, [area=good]good[/area] string." I need to add bbcode to any word that doesn't already have it. For example, the string above should look like: "[area=A]A[/area] [area=very]very[/area], [area=good]good[/area] [area=string]string[/area]." It also needs…

VIEW QUESTION
Back To Top
Search