+ 5
in this âĄ"replace(/[^a-zA-Z0-9]+/g,''); "why.... '/g ' used?
explain me plz...
5 Respostas
+ 1
V-àȘ°àȘŸàȘšà« đđđ that is a g modifier that indicates to search the whole string rather than stopping at the first match to replace.
Here's a reference
https://www.w3schools.com/jsref/jsref_regexp_g.asp
+ 6
Thanks all...đ your information is quite helpful ...
+ 5
global search flag
+ 3
+ 2
Erase ('') all the characters (g modifier) which are not (^) belong character (+)
a to z
A to Z
0 to 9