added permalinks for events with pages for events (with information on how to get there and a twitter card)
parent
2dc21ca3ce
commit
46355ae979
|
@ -139,6 +139,22 @@
|
|||
|
||||
}
|
||||
|
||||
if ( strlen( $parameter ) == 10 ) {
|
||||
|
||||
return $app['twig']->render(
|
||||
'perma-event.twig',
|
||||
array(
|
||||
'page' => 'events',
|
||||
'level2' => Level2::getStatus( $app ),
|
||||
'event' => Level2::getEvent(
|
||||
Level2::getEvents( $app ),
|
||||
$parameter
|
||||
)
|
||||
)
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
return $app['twig']->render(
|
||||
'event-list.twig',
|
||||
array(
|
||||
|
|
|
@ -204,6 +204,22 @@
|
|||
|
||||
}
|
||||
|
||||
static public function getEvent( $events, $startUnix ) {
|
||||
|
||||
$startUnix = (int) $startUnix;
|
||||
|
||||
foreach( $events as $event ) {
|
||||
|
||||
if ( $event[ 'start' ] == $startUnix ) {
|
||||
|
||||
return $event;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
static public function getChartData( $app ) {
|
||||
|
||||
$dowMap = array( 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun' );
|
||||
|
|
|
@ -10,11 +10,13 @@
|
|||
<meta name="apple-mobile-web-app-title" content="Level2">
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
||||
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:site" content="@Level2Lu">
|
||||
<meta name="twitter:title" content="Level2 | a hackerspace in Luxembourg City">
|
||||
<meta name="twitter:description" content="Check out whether we're open, how many people are present right now or what events are scheduled to happen at our place. Swing by to say hello and become a member if you like to =]">
|
||||
<meta name="twitter:image" content="https://files.level2.lu/photos/twitterCard.jpg">
|
||||
{% block twitterCard %}
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:site" content="@Level2Lu">
|
||||
<meta name="twitter:title" content="Level2 | a hackerspace in Luxembourg City">
|
||||
<meta name="twitter:description" content="Check out whether we're open, how many people are present right now or what events are scheduled to happen at our place. Swing by to say hello and become a member if you like to =]">
|
||||
<meta name="twitter:image" content="https://files.level2.lu/photos/twitterCard.jpg">
|
||||
{% endblock twitterCard %}
|
||||
|
||||
<title>Level2</title>
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
<h4>{{ event.date }}</h4>
|
||||
<h4><a class="permaLink" href="/events/{{ event.start }}">{{ event.date }}</a></h4>
|
||||
{% if event.location is defined %}
|
||||
<h4 class="location">{{ event.location }}</h4>
|
||||
{% endif %}
|
||||
|
|
|
@ -0,0 +1,81 @@
|
|||
{% extends "base.twig" %}
|
||||
|
||||
{% block twitterCard %}
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:site" content="@Level2Lu">
|
||||
<meta name="twitter:title" content="Level2 | {{ event.name }}">
|
||||
<meta name="twitter:description" content="{{ event.description }}">
|
||||
<meta name="twitter:image" content="{{ event.image }}">
|
||||
{% endblock twitterCard %}
|
||||
|
||||
{% block container %}
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-8 hidden-xs">
|
||||
|
||||
<section>
|
||||
|
||||
{% embed "event.twig" %}
|
||||
{% endembed %}
|
||||
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<h2 class="well">Map</h2>
|
||||
|
||||
<div class="google-map-container">
|
||||
<a target="_blank" href="https://goo.gl/maps/OWqIf">
|
||||
<img class="google-map no-margin" src="https://files.level2.lu/website/map.png" />
|
||||
</a>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-4">
|
||||
|
||||
<section>
|
||||
|
||||
<h2 class="well">Address</h2>
|
||||
|
||||
<p class="well no-top-radius">
|
||||
Level2<br />
|
||||
87, route de Thionville<br />
|
||||
L-2611 Luxembourg<br />
|
||||
T: <a href="tel:+352-20-333-550">+352 20 333 550</a>
|
||||
</p>
|
||||
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<h2 class="well">Bus</h2>
|
||||
|
||||
<p class="well no-top-radius">
|
||||
The closest bus station is <strong>Neufchâteau</strong>.<br />
|
||||
<strong>Line 16<br />
|
||||
Line 192</strong>
|
||||
</p>
|
||||
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
||||
<h2 class="well">Open the door</h2>
|
||||
|
||||
<h3 class="well no-top-radius">
|
||||
Please call <br /><strong><a href="tel:+352-20-333-550">+352 20 333 550</a></strong><br />
|
||||
if the door is closed.<br />We'll open the door for you.<br />
|
||||
There is no doorbell just yet.
|
||||
</h3>
|
||||
|
||||
</section>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
|
@ -194,3 +194,10 @@ img.emoji {
|
|||
.moreEvents {
|
||||
text-align: right;
|
||||
}
|
||||
a.permaLink, a.permaLink:hover, a.permaLink:link, a.permaLink:active {
|
||||
color: #777777;
|
||||
}
|
||||
a.permaLink:hover {
|
||||
color: #777777;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue