138
rated 0 times
[
143]
[
5]
/ answers: 1 / hits: 36111
/ 11 Years ago, sat, january 4, 2014, 12:00:00
I have this requirement where it is required to remove only the last .
dot sign from a string.
Say if we have var str = 'abcd dhfjd.fhfjd.';
i need remove the final dot sign which would output abcd dhfjd.fhfjd
.
I found this link ( Javascript function to remove leading dot ) which removes the first dot sign but I am new to this whole thing and could not find any source on how to remove a specific last character if exists.
Thank you :)
More From » javascript