Hi, i have a problem with a replacement in a javascript code.
The javascript code is this one:
u see that the second line
With this code, the text "HTML" is getting replaced by second word "HTML" which is in the span id.
I want to replace the text "[HTML]" (without quotes). I tried this one:
but something is not correct so i get this result:
which is the correct code in order to replace
??
The javascript code is this one:
u see that the second line
- Code:
.replace(/HTML/g,"<span id='HTML'>HTML</span>
With this code, the text "HTML" is getting replaced by second word "HTML" which is in the span id.
I want to replace the text "[HTML]" (without quotes). I tried this one:
- Code:
.replace(/[HTML]/g,"<span id='HTML'>HTML</span>
but something is not correct so i get this result:
which is the correct code in order to replace
- Code:
[HTML]
??