javascript - Add a character to the beginning and end of a string -
i using platform uses javascript-like syntax , allows convert values using regex.
i need add single quote @ beginning , @ end of string, string have 9 characters.
i.e.:
123456789
should converted '123456789'
what expression should use?
you don't need regular expression.
str = "123456789"; str = "'" + str + "'";
Comments
Post a Comment