Skip to content

Commit d83bca5

Browse files
committed
Merge pull request #23 from devopsdays/matt-poc
Matt poc
2 parents 762470d + e4e9835 commit d83bca5

File tree

6 files changed

+102
-3
lines changed

6 files changed

+102
-3
lines changed

content/events/2015-chicago/welcome.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ title = "welcome"
66
City = "Chicago"
77
Year = "2015"
88
type = "event"
9+
aliases = ["/events/2015-chicago"]
910
+++
1011

1112
<h2>Tuesday, August 25th and Wednesday, August 26th</h2>

static/img/devopsdays-banner.png

43.7 KB
Loading
Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,21 @@
11
{{ partial "header.html" . }}
2+
<div class = "container-fluid">
3+
<div class = "row">
4+
<div class="col-md-8">
5+
<h1>Upcoming DevOpsDays Events</h1>
6+
<!--map-->
7+
<div id="map_wrapper">
8+
<div id="map_canvas" class="mapping"></div>
9+
</div>
10+
<!-- end map -->
11+
{{ partial "maps" . }}
212

3-
This is the homepage. Edit this and stuff.
13+
</div>
14+
<div class = "col-md-3">
15+
<a class="twitter-timeline" data-dnt="true" href="https://twitter.com/search?q=devopsdays%20OR%20devopsday%20OR%20%23devopsday%20OR%20%23devopsdays" data-widget-id="667543157886816256">Tweets about devopsdays OR devopsday OR #devopsday OR #devopsdays</a>
16+
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
17+
</div>
18+
</div>
19+
</div>
420

521
{{ partial "footer.html" . }}

themes/devopsdays/layouts/partials/header.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,3 +46,4 @@
4646
<div class="container">
4747

4848
<div class="row row-offcanvas row-offcanvas-right">
49+
<img src = "/img/devopsdays-banner.png" class = "image-responsive">
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
2+
<script type="text/javascript">
3+
jQuery(function($) {
4+
// Asynchronously Load the map API
5+
var script = document.createElement('script');
6+
script.src = "http://maps.googleapis.com/maps/api/js?sensor=false&callback=initialize";
7+
document.body.appendChild(script);
8+
});
9+
10+
function initialize() {
11+
var map;
12+
var bounds = new google.maps.LatLngBounds();
13+
var mapOptions = {
14+
mapTypeId: 'roadmap'
15+
};
16+
17+
// Display a map on the page
18+
map = new google.maps.Map(document.getElementById("map_canvas"), mapOptions);
19+
map.setTilt(45);
20+
21+
// Multiple Markers
22+
var markers = [
23+
['Kiel', 54.34208,10.121949],
24+
['Seattle', 47.609895, -122.330259],
25+
['Minneapolis', 44.9726428,-93.2752562],
26+
['Ohio', 39.9833, -82.9833],
27+
['Warsaw', 52.1800879, 20.9788363],
28+
['Washington D.C.', 38.8011545,-77.0659376],
29+
30+
31+
];
32+
33+
// Info Window Content
34+
var infoWindowContent = [
35+
['<div class="info_content">' +
36+
'<h3>London Eye</h3>' +
37+
'<p>The London Eye is a giant Ferris wheel situated on the banks of the River Thames. The entire structure is 135 metres (443 ft) tall and the wheel has a diameter of 120 metres (394 ft).</p>' + '</div>'],
38+
['<div class="info_content">' +
39+
'<h3>Palace of Westminster</h3>' +
40+
'<p>The Palace of Westminster is the meeting place of the House of Commons and the House of Lords, the two houses of the Parliament of the United Kingdom. Commonly known as the Houses of Parliament after its tenants.</p>' +
41+
'</div>']
42+
];
43+
44+
// Display multiple markers on a map
45+
var infoWindow = new google.maps.InfoWindow(), marker, i;
46+
47+
// Loop through our array of markers & place each one on the map
48+
for( i = 0; i < markers.length; i++ ) {
49+
var position = new google.maps.LatLng(markers[i][1], markers[i][2]);
50+
bounds.extend(position);
51+
marker = new google.maps.Marker({
52+
position: position,
53+
map: map,
54+
title: markers[i][0]
55+
});
56+
57+
// Allow each marker to have an info window
58+
google.maps.event.addListener(marker, 'click', (function(marker, i) {
59+
return function() {
60+
infoWindow.setContent(infoWindowContent[i][0]);
61+
infoWindow.open(map, marker);
62+
}
63+
})(marker, i));
64+
65+
// Automatically center the map fitting all markers on the screen
66+
map.fitBounds(bounds);
67+
}
68+
69+
// Override our map zoom level once our fitBounds function runs (Make sure it only runs once)
70+
var boundsListener = google.maps.event.addListener((map), 'bounds_changed', function(event) {
71+
this.setZoom(14);
72+
google.maps.event.removeListener(boundsListener);
73+
});
74+
75+
}
76+
</script>

themes/devopsdays/static/css/style.css

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,11 @@
6262
margin-right: auto;
6363
}
6464

65-
.youtube-video {
66-
margin-bottom: 15px;
65+
#map_wrapper {
66+
height: 400px;
67+
}
68+
69+
#map_canvas {
70+
width: 100%;
71+
height: 100%;
6772
}

0 commit comments

Comments
 (0)