js replace spaces with 20 code example Example: javascript string spaces replace with %20 string.replace()