Skip to content

Instantly share code, notes, and snippets.

View llaumgui's full-sized avatar

Guillaume Kulakowski llaumgui

View GitHub Profile
@lolautruche
lolautruche / ezxml_to_html5.html.twig
Created October 15, 2013 18:29
Convert XmlText to HTML - eZ Publish 5
{% set html = content.getFieldValue( "my_xmltext_field" ).xml|xmltext_to_html5 %}
<div>
{{ html }}
</div>
@lolautruche
lolautruche / controller.php
Last active December 25, 2015 04:39
Pagination in eZ Publish 5
<?php
namespace Acme\TestBundle\Controller;
use eZ\Publish\Core\Pagination\Pagerfanta\ContentSearchAdapter;
use Pagerfanta\Pagerfanta;
use Symfony\Component\HttpFoundation\Response;
use eZ\Bundle\EzPublishCoreBundle\Controller;
use eZ\Publish\API\Repository\Values\Content\Query\Criterion\ContentTypeIdentifier;
use eZ\Publish\API\Repository\Values\Content\Query;