Fix map in photo page
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
title: Dublin - Friday
|
||||
date: 2016-02-26
|
||||
highlight: c8e8e17
|
||||
map:
|
||||
latitude: 53.342753529412
|
||||
longitude: -6.2610924509804
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
title: Dublin - Saturday
|
||||
date: 2016-02-27
|
||||
highlight: bd35101
|
||||
map:
|
||||
latitude: 53.346456884058
|
||||
longitude: -6.2818048550725
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
title: Dublin - Sunday
|
||||
date: 2016-02-28
|
||||
highlight: 011f0d6
|
||||
map:
|
||||
latitude: 53.346554333333
|
||||
longitude: -6.2193251666667
|
||||
|
||||
@@ -10,8 +10,8 @@ layout: default
|
||||
{% if photo.date %}
|
||||
<time datetime="{{ photo.date | date_to_xmlschema }}" title="{{ photo.date | date_to_xmlschema }}"><strong>{{ photo.date | date:"%b %d" | upcase }}</strong><br />{{ photo.date | date:"%Y" }}</time>
|
||||
{% endif %}
|
||||
{% if photo.location %}
|
||||
<a href="https://maps.google.com/maps?hl=en&ll={{ photo.location.latitude }},{{ photo.location.longitude }}&t=w&z=12"><img alt="map" height="49" src="https://maps.googleapis.com/maps/api/staticmap?center={{ photo.location.latitude }},{{ photo.location.longitude }}&zoom=9&size=98x98&sensor=false" title="{{ photo.location.title }}" width="49" /></a>
|
||||
{% if photo.latitude %}
|
||||
<a href="https://maps.google.com/maps?hl=en&ll={{ photo.latitude }},{{ photo.longitude }}&t=w&z=12"><img alt="map" height="49" src="https://maps.googleapis.com/maps/api/staticmap?center={{ photo.latitude }},{{ photo.longitude }}&zoom=9&size=98x98&sensor=false" title="{{ photo.title }}" width="49" /></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<section class="post-content">
|
||||
@@ -112,13 +112,13 @@ layout: default
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
{% if photo.location %}
|
||||
<div style="float:left;line-height:0;margin-left:7px;width:280px;" itemprop="contentLocation" itemscope itemtype="http://schema.org/Place">
|
||||
{% if photo %}
|
||||
<div class="map" itemprop="contentLocation" itemscope itemtype="http://schema.org/Place">
|
||||
<span itemprop="geo" itemscope itemtype="http://schema.org/GeoCoordinates">
|
||||
<meta itemprop="latitude" content="{{ photo.location.latitude }}" />
|
||||
<meta itemprop="longitude" content="{{ photo.location.longitude }}" />
|
||||
<meta itemprop="latitude" content="{{ photo.latitude }}" />
|
||||
<meta itemprop="longitude" content="{{ photo.longitude }}" />
|
||||
</span>
|
||||
<a href="https://maps.google.com/maps?hl=en&ll={{ photo.location.latitude }},{{ photo.location.longitude }}&t=w&z=12"><img alt="map" height="173" src="https://maps.googleapis.com/maps/api/staticmap?center={{ photo.location.latitude }},{{ photo.location.longitude }}&zoom=13&size=280x173&markers=size:mid%7Ccolor:orange%7C{{ photo.location.latitude }},{{ photo.location.longitude }}&sensor=false" title="{{ photo.location.title }}" width="280" /></a>
|
||||
<a href="https://maps.google.com/maps?hl=en&ll={{ photo.latitude }},{{ photo.longitude }}&t=w&z=12"><img alt="map" height="173" src="https://maps.googleapis.com/maps/api/staticmap?center={{ photo.latitude }},{{ photo.longitude }}&zoom=13&size=280x173&markers=size:mid%7Ccolor:orange%7C{{ photo.latitude }},{{ photo.longitude }}&sensor=false" title="{{ photo.title }}" width="280" /></a>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
||||
@@ -418,6 +418,13 @@ blockquote {
|
||||
margin: 0 0 8px;
|
||||
}
|
||||
|
||||
.map {
|
||||
border: 1px solid #ddd;
|
||||
padding: 4px;
|
||||
margin: 0 auto;
|
||||
width :280px;
|
||||
}
|
||||
|
||||
.aligncenter {
|
||||
display: block;
|
||||
margin-left: auto;
|
||||
|
||||
Reference in New Issue
Block a user