Thanks @ Andie2302 for pointing out the right way to do this.
In addition, for many languages of the world, it still has an “extra character”, which requires the main character to be created (for example, the Thai word “เก็บ”, if only \ p {L} is used, it will only display “เก บ”, You can see that some words will be absent in the word).
That is why only \p{L} will not work for all foreign languages.
So you need to use the code below to support an almost foreign language
\p{L}\p{M}
NOTE:
L means "Letter" (all letters in all languages, but not including "Sign")
M stands for "Mark" ("Mark" cannot be displayed separately, it requires "Letter" to display it)
Besides the fact that you need a number, use the code below
\p{N}
NOTE:
N stands for "Numeric"
Thanks to this site for very useful information.
https://www.regular-expressions.info/unicode.html
Sruit A.Suk
source share