Add Coinfest as an international event

This commit is contained in:
Saivann 2015-01-29 11:51:10 -05:00
parent 0db3a01cbe
commit f80aa4be3a
2 changed files with 12 additions and 12 deletions

View file

@ -23,12 +23,10 @@
link: "https://www.ecurex.com/p2pfisy/" link: "https://www.ecurex.com/p2pfisy/"
- date: 2015-02-20 - date: 2015-02-20
title: "#CoinFestRussia. The first decentralized currency convention & International festival" title: "Coinfest. The first decentralized decentralized currency convention"
venue: "ETAZHI loft area, 'Zona Space' coworking center & educational club" city: "Many cities"
address: "Ligovsky Prospect, 74" country: "Worldwide"
city: "Saint-Petersburg" link: "http://www.coinfest.org/"
country: "Russia"
link: "http://coinfestrussia.com"
- date: 2015-02-26 - date: 2015-02-26
title: "Chambe-Carnet: Bitcoin, initiation à largent P2P et opportunités" title: "Chambe-Carnet: Bitcoin, initiation à largent P2P et opportunités"

View file

@ -101,13 +101,15 @@ module Jekyll
date = data['date'].to_s.split('-') date = data['date'].to_s.split('-')
next if Time.new.to_i > (Time.new(date[0].to_i,date[1].to_i,date[2].to_i).to_i + 432000) next if Time.new.to_i > (Time.new(date[0].to_i,date[1].to_i,date[2].to_i).to_i + 432000)
# Get geolocalisation data from Google Maps # Get geolocalisation data from Google Maps
begin if data.has_key?('address')
geoloc = JSON.parse(open("https://maps.googleapis.com/maps/api/geocode/json?address=" + CGI::escape(data['address'] + ', ' + data['city'] + ', ' + data['country']) + "&sensor=false","User-Agent"=>"Ruby/#{RUBY_VERSION}").read) begin
if geoloc['status'] == 'OK' geoloc = JSON.parse(open("https://maps.googleapis.com/maps/api/geocode/json?address=" + CGI::escape(data['address'] + ', ' + data['city'] + ', ' + data['country']) + "&sensor=false","User-Agent"=>"Ruby/#{RUBY_VERSION}").read)
data['geoloc'] = geoloc['results'][0]['geometry']['location']['lat'].to_s + ", " + geoloc['results'][0]['geometry']['location']['lng'].to_s if geoloc['status'] == 'OK'
data['geoloc'] = geoloc['results'][0]['geometry']['location']['lat'].to_s + ", " + geoloc['results'][0]['geometry']['location']['lng'].to_s
end
rescue
print 'Google Maps API Call Failed!'
end end
rescue
print 'Google Maps API Call Failed!'
end end
# Populate conferences array # Populate conferences array
conferences.push(data) conferences.push(data)