I have an application that accepts an address and writes it to the db. I then want to take that address and convert it to something I can send through Google Maps, so I need to replace all the spaces with "+" symbols. I understand how to do that with a regex:
address.gsub(/\s/, "+")
And can create a variable that does it, voila. But I want the converted address to live in the DB as well, so it doesn't have to be processed every time. I'm not sure how I process that when I'm creating the entry to begin with and save it to the db as a separate entity ("gmapaddress" or something).
Thanks!