passive-yellow•2y ago
How to switch Google Maps API "plus Code" format?
Hi, I'm fetching a google "plus code" with the Maps API. In the docs of the maps API is written:
Plus codes must be formatted as a global code or a compound code. Format plus codes as shown here (plus signs are url-escaped to %2B and spaces are url-escaped to %20). Global code is a 4 character area code and 6 character or longer local code (849VCWC8+R9 is 849VCWC8%2BR9).
How can VF change the format? Is there any JS needed?
In my example I have the plus code: 9F3975JR+2X but to call the google maps directions API I need the change the format to 9F3975JR%2B2X
How can I do that? Thank you in advance 🙂
3 Replies
You can use the Set step for that with
encodeURIComponent({variable})


passive-yellowOP•2y ago
Hi NiKo, thank you so much for your answer. Do you also know with Set step I can use to convert Wuppertal Haltestelle Leimbach to Wuppertal+Haltestelle+Leimbach or Wuppertal%20Haltestelle%20Leimbach ?? Thank you in advance
Use the same expression and populate your {variable} with the value you want to encode.
encodeURIComponent({variable})