app/models/location.rb
def to_latlon
    address = address_line_1, address_line_2, address_city, address_state, address_zip
    results = Geocoding::get(address.join(", "))
    results[0].latlon if results.status == Geocoding::GEO_SUCCESS
  end
# Returns an array of Geocoded lat/long for use with Google Maps
Returns an array of Geocoded lat/long for use with Google Maps
Returns an array of Geocoded lat / long for use with Google Maps
def to_latlon
    address = address_line_1, address_line_2, address_city, address_state, address_zip
    results = Geocoding::get(address.join(", "))
    results[0].latlon if results.status == Geocoding::GEO_SUCCESS
  end
def to_latlon address = address_line_1 , address_line_2 , address_city , address_state , address_zip results = Geocoding :: get ( address . join ( ", " ) ) results [ 0 ] . latlon if results . status == Geocoding :: GEO_SUCCESS end
Returns an array of Geocoded lat/long for use with Google Maps
Returns an array of Geocoded lat / long for use with Google Maps