Allow HTML

This commit is contained in:
Oliver Davies 2016-04-13 09:39:00 +01:00
parent 4eaecb9421
commit 4174948cc5
5 changed files with 7 additions and 5 deletions

View file

@ -22,7 +22,7 @@ tweets: yes
{% endblock %}
{% block video %}
{{ youtube('T-miCpHxfds')|raw }}
{{ youtube('T-miCpHxfds') }}
{% endblock %}
{% block feedback %}

View file

@ -27,7 +27,7 @@ I categorised the technical changes into groups for site builders, developers an
{% endblock %}
{% block video %}
{{ youtube('36zCxPrOOzM')|raw }}
{{ youtube('36zCxPrOOzM') }}
{% endblock %}
{% block feedback %}

View file

@ -28,7 +28,7 @@ You can [view the full slides](/slides/phpsw/building-static-websites-with-sculp
{% endblock %}
{% block video %}
{{ youtube('aN53arCKZAU')|raw }}
{{ youtube('aN53arCKZAU') }}
{% endblock %}
{% block feedback %}

View file

@ -15,5 +15,5 @@ An impromptu lightning talk about the [Drupal VM Generator](https://github.com/o
{% block video %}
Here is the recording of the NWDUG March meetup - my talk starts at 01:01:30.
{{ youtube('U1pbKAAO2Wo?s=1h1m31s')|raw }}
{{ youtube('U1pbKAAO2Wo?s=1h1m31s') }}
{% endblock %}

View file

@ -13,7 +13,9 @@ class YouTubeExtension extends Twig_Extension
public function getFunctions()
{
return [
new Twig_SimpleFunction('youtube', [$this, 'embedCode'])
new Twig_SimpleFunction('youtube', [$this, 'embedCode'], [
'is_safe' => ['html']
])
];
}