Created
September 30, 2019 00:58
-
-
Save bogardpd/b41a51abc146220f2bf6140fe7cb8c8d to your computer and use it in GitHub Desktop.
/app/classes/map.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/app/classes/map.rb | |
def gpx | |
output = %Q(<?xml version="1.0" encoding="UTF-8" ?>).html_safe | |
output += content_tag(:gpx, xmlns: "http://www.topografix.com/GPX/1/1", version: "1.1") do | |
concat (content_tag(:metadata) do | |
concat content_tag(:name, map_name) | |
concat content_tag(:desc, map_description) | |
concat (content_tag(:author) do | |
concat content_tag(:name, "Paul Bogard’s Flight Historian") | |
concat content_tag(:link, content_tag(:text, "Paul Bogard’s Flight Historian"), href: "https://www.flighthistorian.com") | |
end) | |
end) | |
# (airport code here) | |
# (route code here) | |
end | |
return output | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment