Sha256: 8616ea03711099e45052b01675c9987715831bb01899e5466da3e7d47081d2e0

Contents?: true

Size: 417 Bytes

Versions: 2

Compression:

Stored size: 417 Bytes

Contents

module GoogleMapsRails
  module ViewHelpers
    def embed_google_maps(lat, long, width = 500, height = 500)
      if lat != '' && long != ''
        "<iframe src = 'https://maps.google.com/maps?q=#{lat},#{long}&hl=es;z=14&amp;output=embed' frameborder='0' style='border:0' width='#{width}' height='#{height}' allowfullscreen></iframe>"
      else
        "latitude or longitude not found"
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
google_maps_rails-0.0.2 lib/google_maps_rails/view_helpers.rb
google_maps_rails-0.0.1 lib/google_maps_rails/view_helpers.rb