<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
/* front/theme1/page_ref.html.twig */
class __TwigTemplate_dfd58cc6963cdeeb37550a88e267ff4a extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'preload' => [$this, 'block_preload'],
'stylesheets' => [$this, 'block_stylesheets'],
'body' => [$this, 'block_body'],
'javascripts' => [$this, 'block_javascripts'],
];
}
protected function doGetParent(array $context)
{
// line 1
return $this->loadTemplate((("front/" . twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 1, $this->source); })()), "request", [], "any", false, false, false, 1), "server", [], "any", false, false, false, 1), "get", [0 => "APP_THEME"], "method", false, false, false, 1)) . "/base.html.twig"), "front/theme1/page_ref.html.twig", 1);
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "front/theme1/page_ref.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "front/theme1/page_ref.html.twig"));
$this->getParent($context)->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
public function block_preload($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "preload"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "preload"));
// line 4
echo " ";
if ((twig_get_attribute($this->env, $this->source, ($context["post"] ?? null), "image", [], "any", true, true, false, 4) && !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 4, $this->source); })()), "image", [], "any", false, false, false, 4)))) {
// line 5
echo " ";
if (twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 5, $this->source); })()), "image", [], "any", false, false, false, 5)) {
// line 6
echo " <link rel=\"preload\" as=\"image\" href=\"";
echo twig_escape_filter($this->env, $this->extensions['App\Twig\ImagesExtenstion']->AssetImageFunction(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 6, $this->source); })()), "image", [], "any", false, false, false, 6)), "html", null, true);
echo "\" />
";
}
// line 8
echo " ";
}
// line 9
echo "
";
// line 10
if ((array_key_exists("galleries", $context) && !twig_test_empty((isset($context["galleries"]) || array_key_exists("galleries", $context) ? $context["galleries"] : (function () { throw new RuntimeError('Variable "galleries" does not exist.', 10, $this->source); })())))) {
// line 11
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["galleries"]) || array_key_exists("galleries", $context) ? $context["galleries"] : (function () { throw new RuntimeError('Variable "galleries" does not exist.', 11, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 12
echo " ";
if (twig_get_attribute($this->env, $this->source, $context["item"], "path", [], "any", true, true, false, 12)) {
// line 13
echo " <link rel=\"preload\" as=\"image\" href=\"";
echo twig_escape_filter($this->env, $this->extensions['App\Twig\ImagesExtenstion']->AssetImageGalleryFunction(twig_get_attribute($this->env, $this->source, $context["item"], "path", [], "any", false, false, false, 13)), "html", null, true);
echo "\" />
";
}
// line 15
echo " ";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 16
echo " ";
}
// line 17
echo "
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 20
public function block_stylesheets($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheets"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheets"));
// line 21
echo " ";
$this->displayParentBlock("stylesheets", $context, $blocks);
echo "
";
// line 22
if ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["modele_galerie"]) || array_key_exists("modele_galerie", $context) ? $context["modele_galerie"] : (function () { throw new RuntimeError('Variable "modele_galerie" does not exist.', 22, $this->source); })()), 0, [], "array", false, false, false, 22), "type", [], "any", false, false, false, 22) == 4)) {
// line 23
echo " <link rel=\"stylesheet\" type=\"text/css\" href=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("templates/front/theme1/assets/plugins/flexslider/flexslider.css"), "html", null, true);
echo "\" media=\"screen\" >
";
}
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 27
public function block_body($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "body"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "body"));
// line 28
echo "
<div class=\"page_cms page_activite pt-5\">
<div class=\"breadcrumb-style-default\">
<div class=\"container\">
<div class=\"row\">
<div class=\"col-lg-12\">
<div class=\"inner text-center\">
";
// line 35
if ((array_key_exists("breadcrumb", $context) && !twig_test_empty((isset($context["breadcrumb"]) || array_key_exists("breadcrumb", $context) ? $context["breadcrumb"] : (function () { throw new RuntimeError('Variable "breadcrumb" does not exist.', 35, $this->source); })())))) {
// line 36
echo " ";
echo twig_include($this->env, $context, (("front/" . twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 36, $this->source); })()), "request", [], "any", false, false, false, 36), "server", [], "any", false, false, false, 36), "get", [0 => "APP_THEME"], "method", false, false, false, 36)) . "/partials/breadcrumb.html.twig"));
echo "
<h1 class=\"page-title\">";
// line 37
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, twig_last($this->env, (isset($context["breadcrumb"]) || array_key_exists("breadcrumb", $context) ? $context["breadcrumb"] : (function () { throw new RuntimeError('Variable "breadcrumb" does not exist.', 37, $this->source); })())), "name", [], "any", false, false, false, 37), "html", null, true);
echo "</h1>
";
}
// line 39
echo " </div>
</div>
</div>
</div>
</div>
<div class=\"container-fluid wrapper mt-3\">
<div class=\"row gx-5 py-2\">
";
// line 47
if (( !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 47, $this->source); })()), "summary", [], "any", false, false, false, 47)) && (twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 47, $this->source); })()), "summary", [], "any", false, false, false, 47) != ""))) {
// line 48
echo " <div class=\"col-sm-12 text-center\">
<h2 class=\"sub-title wow\">";
// line 49
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 49, $this->source); })()), "summary", [], "any", false, false, false, 49), "html", null, true);
echo "</h2>
</div>
";
}
// line 52
echo "
";
// line 53
if ((twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 53, $this->source); })()), "image", [], "any", false, false, false, 53) && !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 53, $this->source); })()), "image", [], "any", false, false, false, 53)))) {
// line 54
echo " <div class=\"col-sm-12 text-center my-4\">
<img class=\"lazyload img-fluid principal-img\" data-srcset=\"";
// line 55
echo twig_escape_filter($this->env, $this->extensions['App\Twig\ImagesExtenstion']->AssetImageFunction(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 55, $this->source); })()), "image", [], "any", false, false, false, 55)), "html", null, true);
echo "\" src=\"";
echo twig_escape_filter($this->env, $this->extensions['App\Twig\ImagesExtenstion']->AssetImageFunction(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 55, $this->source); })()), "image", [], "any", false, false, false, 55)), "html", null, true);
echo "\" alt=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 55, $this->source); })()), "title", [], "any", false, false, false, 55), "html", null, true);
echo "\" />
</div>
";
}
// line 58
echo "
";
// line 59
if (( !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 59, $this->source); })()), "content", [], "any", false, false, false, 59)) && (twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 59, $this->source); })()), "content", [], "any", false, false, false, 59) != ""))) {
// line 60
echo " <div class=\"col-lg-12 content_post\">
";
// line 61
echo twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 61, $this->source); })()), "content", [], "any", false, false, false, 61);
echo "
";
// line 63
if ((twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 63, $this->source); })()), "typelien", [], "any", false, false, false, 63) == null)) {
// line 64
echo " ";
if ((array_key_exists("categorieTree", $context) && twig_get_attribute($this->env, $this->source, ($context["categorieTree"] ?? null), 0, [], "array", true, true, false, 64))) {
// line 65
echo " <div class=\"text-center py-2\">
<a href=\"";
// line 66
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("page", ["slug" => twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["categorieTree"]) || array_key_exists("categorieTree", $context) ? $context["categorieTree"] : (function () { throw new RuntimeError('Variable "categorieTree" does not exist.', 66, $this->source); })()), 0, [], "array", false, false, false, 66), "slug", [], "any", false, false, false, 66)]), "html", null, true);
echo "\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">Retour à la liste ";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["categorieTree"]) || array_key_exists("categorieTree", $context) ? $context["categorieTree"] : (function () { throw new RuntimeError('Variable "categorieTree" does not exist.', 66, $this->source); })()), 0, [], "array", false, false, false, 66), "titre", [], "any", false, false, false, 66), "html", null, true);
echo "</a>
</div>
";
}
// line 69
echo " ";
} elseif ((twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 69, $this->source); })()), "typelien", [], "any", false, false, false, 69) != 1)) {
// line 70
echo " ";
if ((twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 70, $this->source); })()), "typelien", [], "any", false, false, false, 70) == "4")) {
// line 71
echo " <div class=\"text-center py-2\">
<a href=\"javascript:void(0)\" onclick=\"window.location.href = 'tel:";
// line 72
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 72, $this->source); })()), "telephone", [], "any", false, false, false, 72), "html", null, true);
echo "';\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 72, $this->source); })()), "titrelien", [], "any", false, false, false, 72), "html", null, true);
echo "</a>
</div>
";
} elseif ((twig_get_attribute($this->env, $this->source, // line 74
(isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 74, $this->source); })()), "typelien", [], "any", false, false, false, 74) == "2")) {
// line 75
echo " <div class=\"text-center py-2\">
<a href=\"";
// line 76
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 76, $this->source); })()), "lieninterne", [], "any", false, false, false, 76), "html", null, true);
echo "\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 76, $this->source); })()), "titrelien", [], "any", false, false, false, 76), "html", null, true);
echo "</a>
</div>
";
} elseif ((twig_get_attribute($this->env, $this->source, // line 78
(isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 78, $this->source); })()), "typelien", [], "any", false, false, false, 78) == "3")) {
// line 79
echo " <div class=\"text-center py-2\">
<a href=\"";
// line 80
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 80, $this->source); })()), "lienexterne", [], "any", false, false, false, 80), "html", null, true);
echo "\" target=\"_blank\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 80, $this->source); })()), "titrelien", [], "any", false, false, false, 80), "html", null, true);
echo "</a>
</div>
";
}
// line 83
echo " ";
}
// line 84
echo "
";
// line 85
if (((isset($context["docs"]) || array_key_exists("docs", $context) ? $context["docs"] : (function () { throw new RuntimeError('Variable "docs" does not exist.', 85, $this->source); })()) && !twig_test_empty((isset($context["docs"]) || array_key_exists("docs", $context) ? $context["docs"] : (function () { throw new RuntimeError('Variable "docs" does not exist.', 85, $this->source); })())))) {
// line 86
echo " <div class=\"col-md-12 bloc-docs d-flex justify-content-center\">
";
// line 87
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["docs"]) || array_key_exists("docs", $context) ? $context["docs"] : (function () { throw new RuntimeError('Variable "docs" does not exist.', 87, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["doc"]) {
// line 88
echo " <a class=\"btn-back-pulse m-2\" href=\"";
echo twig_escape_filter($this->env, (((twig_get_attribute($this->env, $this->source, $context["doc"], "location", [], "any", false, false, false, 88) . twig_get_attribute($this->env, $this->source, $context["doc"], "path", [], "any", false, false, false, 88)) . "/") . twig_get_attribute($this->env, $this->source, $context["doc"], "fileName", [], "any", false, false, false, 88)), "html", null, true);
echo "\" title=\"";
echo twig_escape_filter($this->env, twig_slice($this->env, twig_get_attribute($this->env, $this->source, $context["doc"], "fileName", [], "any", false, false, false, 88), 0, -4), "html", null, true);
echo "\" target=\"_blank\"><i class=\"fa fa-file-pdf-o mr-2\"></i>";
echo twig_escape_filter($this->env, twig_slice($this->env, twig_get_attribute($this->env, $this->source, $context["doc"], "fileName", [], "any", false, false, false, 88), 0, -4), "html", null, true);
echo "</a>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['doc'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 90
echo " </div>
";
}
// line 92
echo "
</div>
";
}
// line 96
echo " </div>
";
// line 98
if (((array_key_exists("next_article", $context) && !twig_test_empty((isset($context["next_article"]) || array_key_exists("next_article", $context) ? $context["next_article"] : (function () { throw new RuntimeError('Variable "next_article" does not exist.', 98, $this->source); })()))) || (array_key_exists("prev_article", $context) && !twig_test_empty((isset($context["prev_article"]) || array_key_exists("prev_article", $context) ? $context["prev_article"] : (function () { throw new RuntimeError('Variable "prev_article" does not exist.', 98, $this->source); })()))))) {
// line 99
echo " <div class=\"row gx-5 py-4\">
<div class=\"col-lg-12 d-flex justify-content-between\">
<div class=\"\">
";
// line 102
if ((array_key_exists("prev_article", $context) && !twig_test_empty((isset($context["prev_article"]) || array_key_exists("prev_article", $context) ? $context["prev_article"] : (function () { throw new RuntimeError('Variable "prev_article" does not exist.', 102, $this->source); })())))) {
// line 103
echo " <a href=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("page", ["slug" => twig_get_attribute($this->env, $this->source, (isset($context["prev_article"]) || array_key_exists("prev_article", $context) ? $context["prev_article"] : (function () { throw new RuntimeError('Variable "prev_article" does not exist.', 103, $this->source); })()), "slug", [], "any", false, false, false, 103)]), "html", null, true);
echo "\" title=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["prev_article"]) || array_key_exists("prev_article", $context) ? $context["prev_article"] : (function () { throw new RuntimeError('Variable "prev_article" does not exist.', 103, $this->source); })()), "title", [], "any", false, false, false, 103), "html", null, true);
echo "\"><span class=\"signe1\"><i class=\"fa fa-arrow-left\"></i></span> ";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["prev_article"]) || array_key_exists("prev_article", $context) ? $context["prev_article"] : (function () { throw new RuntimeError('Variable "prev_article" does not exist.', 103, $this->source); })()), "title", [], "any", false, false, false, 103), "html", null, true);
echo "</a>
";
}
// line 105
echo " </div>
<div class=\"\">
";
// line 107
if ((array_key_exists("next_article", $context) && !twig_test_empty((isset($context["next_article"]) || array_key_exists("next_article", $context) ? $context["next_article"] : (function () { throw new RuntimeError('Variable "next_article" does not exist.', 107, $this->source); })())))) {
// line 108
echo " <a href=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("page", ["slug" => twig_get_attribute($this->env, $this->source, (isset($context["next_article"]) || array_key_exists("next_article", $context) ? $context["next_article"] : (function () { throw new RuntimeError('Variable "next_article" does not exist.', 108, $this->source); })()), "slug", [], "any", false, false, false, 108)]), "html", null, true);
echo "\" title=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["next_article"]) || array_key_exists("next_article", $context) ? $context["next_article"] : (function () { throw new RuntimeError('Variable "next_article" does not exist.', 108, $this->source); })()), "title", [], "any", false, false, false, 108), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["next_article"]) || array_key_exists("next_article", $context) ? $context["next_article"] : (function () { throw new RuntimeError('Variable "next_article" does not exist.', 108, $this->source); })()), "title", [], "any", false, false, false, 108), "html", null, true);
echo " <span class=\"signe1\"><i class=\"fa fa-arrow-right\"></i></span></a>
";
}
// line 110
echo " </div>
</div>
</div>
";
}
// line 114
echo " </div>
";
// line 155
echo "
";
// line 156
if (((((isset($context["galleries"]) || array_key_exists("galleries", $context) ? $context["galleries"] : (function () { throw new RuntimeError('Variable "galleries" does not exist.', 156, $this->source); })()) && !twig_test_empty((isset($context["galleries"]) || array_key_exists("galleries", $context) ? $context["galleries"] : (function () { throw new RuntimeError('Variable "galleries" does not exist.', 156, $this->source); })()))) && array_key_exists("template_model_gallerie", $context)) && !twig_test_empty((isset($context["template_model_gallerie"]) || array_key_exists("template_model_gallerie", $context) ? $context["template_model_gallerie"] : (function () { throw new RuntimeError('Variable "template_model_gallerie" does not exist.', 156, $this->source); })())))) {
// line 157
echo " ";
echo twig_include($this->env, $context, twig_template_from_string($this->env, (isset($context["template_model_gallerie"]) || array_key_exists("template_model_gallerie", $context) ? $context["template_model_gallerie"] : (function () { throw new RuntimeError('Variable "template_model_gallerie" does not exist.', 157, $this->source); })())));
echo "
";
}
// line 159
echo "
";
// line 160
if ( !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 160, $this->source); })()), "urlvideo", [], "any", false, false, false, 160))) {
// line 161
echo " <div class=\"container-fluid wrapper mt-3\">
<div class=\"col-md-12 mt-1\">
<div class=\"video\">
";
// line 164
$context["id_video_externe"] = twig_get_attribute($this->env, $this->source, twig_split_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 164, $this->source); })()), "urlvideo", [], "any", false, false, false, 164), "?v="), 1, [], "array", false, false, false, 164);
// line 165
echo " <a class=\"video-thumbnail m-0\" href=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["post"]) || array_key_exists("post", $context) ? $context["post"] : (function () { throw new RuntimeError('Variable "post" does not exist.', 165, $this->source); })()), "urlvideo", [], "any", false, false, false, 165), "html", null, true);
echo "\" data-fancybox=\"video\">
<img src=\"https://img.youtube.com/vi/";
// line 166
echo twig_escape_filter($this->env, (isset($context["id_video_externe"]) || array_key_exists("id_video_externe", $context) ? $context["id_video_externe"] : (function () { throw new RuntimeError('Variable "id_video_externe" does not exist.', 166, $this->source); })()), "html", null, true);
echo "/maxresdefault.jpg\" class=\"img-fluid\" alt=\"\"/>
</a>
</div>
</div>
</div>
";
}
// line 172
echo "
";
// line 173
if (array_key_exists("blocs", $context)) {
// line 174
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["blocs"]) || array_key_exists("blocs", $context) ? $context["blocs"] : (function () { throw new RuntimeError('Variable "blocs" does not exist.', 174, $this->source); })()), "Bloc", [], "any", false, false, false, 174));
foreach ($context['_seq'] as $context["_key"] => $context["bloc"]) {
// line 175
echo " ";
if (($this->extensions['MobileDetectBundle\Twig\Extension\MobileDetectExtension']->isMobile() && (twig_get_attribute($this->env, $this->source, $context["bloc"], "mobile", [], "any", false, false, false, 175) == true))) {
// line 176
echo " ";
echo twig_include($this->env, $context, (("front/" . twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 176, $this->source); })()), "request", [], "any", false, false, false, 176), "server", [], "any", false, false, false, 176), "get", [0 => "APP_THEME"], "method", false, false, false, 176)) . "/bloc/bloc.html.twig"), ["bloc" => // line 177
$context["bloc"]], false);
// line 178
echo "
";
}
// line 180
echo "
";
// line 181
if ((($this->extensions['MobileDetectBundle\Twig\Extension\MobileDetectExtension']->isFullView() && ($this->extensions['MobileDetectBundle\Twig\Extension\MobileDetectExtension']->isMobile() == false)) && (twig_get_attribute($this->env, $this->source, $context["bloc"], "desktop", [], "any", false, false, false, 181) == true))) {
// line 182
echo " ";
echo twig_include($this->env, $context, (("front/" . twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 182, $this->source); })()), "request", [], "any", false, false, false, 182), "server", [], "any", false, false, false, 182), "get", [0 => "APP_THEME"], "method", false, false, false, 182)) . "/bloc/bloc.html.twig"), ["bloc" => // line 183
$context["bloc"]], false);
// line 184
echo "
";
}
// line 186
echo " ";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['bloc'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 187
echo " ";
}
echo "
</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 192
public function block_javascripts($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascripts"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascripts"));
// line 193
echo " ";
$this->displayParentBlock("javascripts", $context, $blocks);
echo "
<script src=\"";
// line 194
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("assets-admin/plugins/form-builder-io/formio.full.min.js"), "html", null, true);
echo "\"></script>
<script src=\"https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js\"></script>
<script>
var current_fs, next_fs, previous_fs;
var left, opacity, scale;
var animating;
\$(\".next\").click(function(){
current_fs = \$(this).parent();
next_fs = \$(this).parent().next();
if (!validateForm(current_fs)) {
return false;
}
if(animating) return false;
animating = true;
\$(\"#progressbar li\").eq(\$(\"fieldset\").index(next_fs)).addClass(\"active\");
next_fs.show();
//hide the current fieldset with style
current_fs.animate({opacity: 0}, {
step: function(now, mx) {
//as the opacity of current_fs reduces to 0 - stored in \"now\"
//1. scale current_fs down to 80%
scale = 1 - (1 - now) * 0.2;
//2. bring next_fs from the right(50%)
left = (now * 50)+\"%\";
//3. increase opacity of next_fs to 1 as it moves in
opacity = 1 - now;
current_fs.css({
'transform': 'scale('+scale+')',
'position': 'absolute'
});
next_fs.css({'left': left, 'opacity': opacity});
},
duration: 1000,
complete: function(){
current_fs.hide();
animating = false;
},
//this comes from the custom easing plugin
easing: 'easeInOutBack'
});
});
\$(\".previous\").click(function(){
current_fs = \$(this).parent();
previous_fs = \$(this).parent().prev();
// if (!validateForm(current_fs)) {
// return false;
// }
if(animating) return false;
animating = true;
//de-activate current step on progressbar
\$(\"#progressbar li\").eq(\$(\"fieldset\").index(current_fs)).removeClass(\"active\");
//show the previous fieldset
previous_fs.show();
//hide the current fieldset with style
previous_fs.css({'transform': 'scale(1)', 'opacity': '1','position':'relative'});
current_fs.hide();
animating = false;
// current_fs.animate({opacity: 0}, {
// step: function(now, mx) {
// //as the opacity of current_fs reduces to 0 - stored in \"now\"
// //1. scale previous_fs from 80% to 100%
// scale = 0.8 + (1 - now) * 0.2;
// //2. take current_fs to the right(50%) - from 0%
// left = ((1-now) * 50)+\"%\";
// //3. increase opacity of previous_fs to 1 as it moves in
// opacity = 1 - now;
// current_fs.css({'left': left});
// previous_fs.css({'transform': 'scale('+scale+')', 'opacity': opacity,'position':'relative'});
// },
// duration: 800,
// complete: function(){
// current_fs.hide();
// animating = false;
// },
// //this comes from the custom easing plugin
// easing: 'easeInOutBack'
// });
});
// \$(\".form-wizrd .submit.action-button\").click(function(e){
// current_fs = \$(this).parent();
// if (!validateForm(current_fs)) {
// return false;
// }
// });
function validateForm(current_fs) {
let formTabs, formInputs, i, valid = true;
formInputs = current_fs[0].querySelectorAll('[data-form-input]');
for (i = 0; i < formInputs.length; i++) {
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') != 'checkbox') {
formInputs[i].addEventListener('keyup', (event) => {
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
// event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') == 'checkbox') {
formInputs[i].addEventListener('change', (event) => {
if(\$(event.target).is(':checked')){
\$(event.target).attr('checked', true);
}else{
\$(event.target).attr('checked', false);
}
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
//event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && formInputs[i].nodeName == 'SELECT') {
formInputs[i].addEventListener('change', (event) => {
console.log('select change');
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
//event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') == 'email') {
formInputs[i].addEventListener('keyup', (event) => {
console.log(isEmail(event.target.value));
if (isEmail(event.target.value) == true) {
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
}else{
if (!event.target.classList.contains('has-error')) {
event.target.className += \" has-error\";
}
\$(event.target.parentElement).find('.invalid-feedback').html('Veuillez choisir un email valide.');
\$(event.target.parentElement).find('.invalid-feedback').css('display','block');
}
// event.target.nextElementSibling.style.display = \"none\";
});
}
if(formInputs[i].hasAttribute(\"required\")){
if (\$(formInputs[i]).attr('type') == 'checkbox' && \$(formInputs[i]).is(':checked') == false) {
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}else if(formInputs[i].value == \"\" && (\$(formInputs[i]).attr('type') == 'text' || formInputs[i].nodeName == 'SELECT' || formInputs[i].nodeName == 'TEXTAREA')){
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}else if(!isEmail(formInputs[i].value) && \$(formInputs[i]).attr('type') == 'email'){
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}
//formInputs[i].nextElementSibling.style.display = \"block\";
}
}
return valid;
}
function isEmail(email) {
var EmailRegex = /^([a-zA-Z0-9_.+-])+\\@(([a-zA-Z0-9-])+\\.)+([a-zA-Z0-9]{2,4})+\$/;
return EmailRegex.test(email);
}
</script>
<script>
if(document.getElementById(\"builder\")){
var data_fields = document.getElementById(\"builder\").getAttribute('data-config');
if(data_fields != ''){
data_fields = JSON.parse(data_fields);
console.log(JSON.parse(data_fields));
Formio.createForm(document.getElementById('builder'),
JSON.parse(data_fields),
).then(function(form) {
// Prevent the submission from going to the form.io server.
form.nosubmit = true;
// Triggered when they click the submit button.
form.on('submit', function(submission) {
var data = submission.data;
grecaptcha.execute('";
// line 398
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $this->extensions['App\Twig\ParametreSiteExtension']->ParametreSiteFunction(), "clekey", [], "any", false, false, false, 398), "html", null, true);
echo "', {action: 'create_comment'}).then(token => {
\$('#builder').find('[name=g-recaptcha-response]').val(token);
data['g-recaptcha-response'] = token;
data['IdForm'] = \$('#builder').parent().find('input[name=\"IdForm\"]').val();
\$('#builder').parent().find('button[type=\"submit\"]').attr('disabled','true');
\$.ajax({
type:\"POST\",
cache:false,
url:\"";
// line 406
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("save_form");
echo "\",
data:data,
success: function (data) {
window.location = data
}
});
});
});
});
}
}
</script>
";
// line 419
if ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["modele_galerie"]) || array_key_exists("modele_galerie", $context) ? $context["modele_galerie"] : (function () { throw new RuntimeError('Variable "modele_galerie" does not exist.', 419, $this->source); })()), 0, [], "array", false, false, false, 419), "type", [], "any", false, false, false, 419) == 4)) {
// line 420
echo " ";
$this->displayParentBlock("javascripts", $context, $blocks);
echo "
<script src=\"";
// line 421
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("templates/front/theme1/assets/plugins/flexslider/jquery.flexslider.js"), "html", null, true);
echo "\" ></script>
<script>
/*-------------------------------------------------*/
/* = Sx flexslider
/*-------------------------------------------------*/
if (\$(\".sx_flexslider\").length) {
\$('.flex-carousel').flexslider({
animation: \"slide\",
controlNav: false,
animationLoop: true,
slideshow: false,
itemWidth: 150,
asNavFor: '.flex-slider'
});
\$('.flex-slider').flexslider({
animation: \"slide\",
controlNav: false,
animationLoop: true,
slideshow: false,
sync: \".flex-carousel\"
});
}
</script>
";
}
// line 445
echo "
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "front/theme1/page_ref.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 757 => 445, 730 => 421, 725 => 420, 723 => 419, 707 => 406, 696 => 398, 489 => 194, 484 => 193, 474 => 192, 459 => 187, 453 => 186, 449 => 184, 447 => 183, 445 => 182, 443 => 181, 440 => 180, 436 => 178, 434 => 177, 432 => 176, 429 => 175, 424 => 174, 422 => 173, 419 => 172, 410 => 166, 405 => 165, 403 => 164, 398 => 161, 396 => 160, 393 => 159, 387 => 157, 385 => 156, 382 => 155, 378 => 114, 372 => 110, 362 => 108, 360 => 107, 356 => 105, 346 => 103, 344 => 102, 339 => 99, 337 => 98, 333 => 96, 327 => 92, 323 => 90, 310 => 88, 306 => 87, 303 => 86, 301 => 85, 298 => 84, 295 => 83, 287 => 80, 284 => 79, 282 => 78, 275 => 76, 272 => 75, 270 => 74, 263 => 72, 260 => 71, 257 => 70, 254 => 69, 246 => 66, 243 => 65, 240 => 64, 238 => 63, 233 => 61, 230 => 60, 228 => 59, 225 => 58, 215 => 55, 212 => 54, 210 => 53, 207 => 52, 201 => 49, 198 => 48, 196 => 47, 186 => 39, 181 => 37, 176 => 36, 174 => 35, 165 => 28, 155 => 27, 141 => 23, 139 => 22, 134 => 21, 124 => 20, 113 => 17, 110 => 16, 104 => 15, 98 => 13, 95 => 12, 90 => 11, 88 => 10, 85 => 9, 82 => 8, 76 => 6, 73 => 5, 70 => 4, 60 => 3, 38 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends \"front/\"~ app.request.server.get('APP_THEME') ~\"/base.html.twig\" %}
{% block preload %}
{% if post.image is defined and post.image is not empty %}
{% if post.image %}
<link rel=\"preload\" as=\"image\" href=\"{{asset_image(post.image)}}\" />
{% endif %}
{% endif %}
{% if galleries is defined and galleries is not empty %}
{% for item in galleries %}
{% if item.path is defined %}
<link rel=\"preload\" as=\"image\" href=\"{{asset_image_gallery(item.path)}}\" />
{% endif %}
{% endfor %}
{% endif %}
{% endblock %}
{% block stylesheets %}
{{parent()}}
{% if modele_galerie[0].type == 4 %}
<link rel=\"stylesheet\" type=\"text/css\" href=\"{{asset('templates/front/theme1/assets/plugins/flexslider/flexslider.css')}}\" media=\"screen\" >
{% endif %}
{% endblock %}
{% block body %}
<div class=\"page_cms page_activite pt-5\">
<div class=\"breadcrumb-style-default\">
<div class=\"container\">
<div class=\"row\">
<div class=\"col-lg-12\">
<div class=\"inner text-center\">
{% if breadcrumb is defined and breadcrumb is not empty %}
{{ include ('front/'~ app.request.server.get('APP_THEME') ~'/partials/breadcrumb.html.twig')}}
<h1 class=\"page-title\">{{breadcrumb|last.name}}</h1>
{% endif %}
</div>
</div>
</div>
</div>
</div>
<div class=\"container-fluid wrapper mt-3\">
<div class=\"row gx-5 py-2\">
{% if post.summary is not empty and post.summary != \"\" %}
<div class=\"col-sm-12 text-center\">
<h2 class=\"sub-title wow\">{{post.summary}}</h2>
</div>
{% endif %}
{% if post.image and post.image is not empty %}
<div class=\"col-sm-12 text-center my-4\">
<img class=\"lazyload img-fluid principal-img\" data-srcset=\"{{asset_image(post.image)}}\" src=\"{{asset_image(post.image)}}\" alt=\"{{post.title}}\" />
</div>
{% endif %}
{% if post.content is not empty and post.content != \"\" %}
<div class=\"col-lg-12 content_post\">
{{post.content|raw}}
{% if post.typelien == null %}
{% if categorieTree is defined and categorieTree[0] is defined %}
<div class=\"text-center py-2\">
<a href=\"{{path('page',{slug:categorieTree[0].slug})}}\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">Retour à la liste {{categorieTree[0].titre}}</a>
</div>
{% endif %}
{% elseif post.typelien != 1 %}
{% if post.typelien == '4' %}
<div class=\"text-center py-2\">
<a href=\"javascript:void(0)\" onclick=\"window.location.href = 'tel:{{post.telephone}}';\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">{{post.titrelien}}</a>
</div>
{% elseif post.typelien == '2' %}
<div class=\"text-center py-2\">
<a href=\"{{post.lieninterne}}\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">{{post.titrelien}}</a>
</div>
{% elseif post.typelien == '3' %}
<div class=\"text-center py-2\">
<a href=\"{{post.lienexterne}}\" target=\"_blank\" class=\"btn btn-primary py-3 px-5 mt-3 btn-plus\">{{post.titrelien}}</a>
</div>
{% endif %}
{% endif %}
{% if docs and docs is not empty %}
<div class=\"col-md-12 bloc-docs d-flex justify-content-center\">
{% for doc in docs %}
<a class=\"btn-back-pulse m-2\" href=\"{{doc.location ~ doc.path ~ '/' ~ doc.fileName}}\" title=\"{{doc.fileName|slice(0, -4)}}\" target=\"_blank\"><i class=\"fa fa-file-pdf-o mr-2\"></i>{{doc.fileName|slice(0, -4)}}</a>
{% endfor %}
</div>
{% endif %}
</div>
{% endif %}
</div>
{% if next_article is defined and next_article is not empty or prev_article is defined and prev_article is not empty %}
<div class=\"row gx-5 py-4\">
<div class=\"col-lg-12 d-flex justify-content-between\">
<div class=\"\">
{% if prev_article is defined and prev_article is not empty %}
<a href=\"{{path('page',{'slug':prev_article.slug})}}\" title=\"{{prev_article.title}}\"><span class=\"signe1\"><i class=\"fa fa-arrow-left\"></i></span> {{prev_article.title}}</a>
{% endif %}
</div>
<div class=\"\">
{% if next_article is defined and next_article is not empty %}
<a href=\"{{path('page',{'slug':next_article.slug})}}\" title=\"{{next_article.title}}\">{{next_article.title}} <span class=\"signe1\"><i class=\"fa fa-arrow-right\"></i></span></a>
{% endif %}
</div>
</div>
</div>
{% endif %}
</div>
{# {% if actualite_ref is defined and actualite_ref is not empty %}
<div class=\"container-fluid wrapper mt-3\">
<div class=\"row gx-5 py-2\">
<div class=\"col-sm-12 text-center\">
<h2 class=\"sub-title wow\">Nos autres prestations autour de {{secteur.titre}}</h2>
</div>
<div class=\"col-sm-12\">
<div class=\"list_blocs pos1\">
<div class=\"blocs\">
<section id=\"results\" class=\"results dynam-affichage affichage1 type_affiche3\">
{% for item in actualite_ref %}
{% set duree = 0.1 %}
{% set image_item = item.image != null? asset_image(item.image):'uploads/images/' ~ parametre.imagevide %}
<a class=\"article wow zoomIn animated\" data-wow-delay=\"{{duree}}s\" href=\"{{path('page',{slug:item.slug})}}\" title=\"\" style=\"visibility: visible; animation-delay: 0.1s; animation-name: zoomIn;\">
<span class=\"article-image lazyloaded\" style=\"background-image: url({{image_item}}); background-size: cover; background-position: center center; background-repeat: no-repeat;\"> </span>
<span class=\"article-cnt\">
<h3 class=\"article-titre\">{{item.title}}</h3>
<span class=\"article-txt\">
{% if item.summary is not empty %}
{{item.summary|raw}}
{% else %}
{{cutText(item.content)|raw}}
{% endif %}
</span>
<span class=\"article-bts\">
<span class=\"article-plus btn-fade\">En savoir plus</span>
</span>
</span>
</a>
{% set duree = duree + 0.2 %}
{% endfor %}
</section>
</div>
</div>
</div>
</div>
</div>
{% endif %} #}
{% if galleries and galleries is not empty and template_model_gallerie is defined and template_model_gallerie is not empty %}
{{ include(template_from_string(template_model_gallerie)) }}
{% endif %}
{% if post.urlvideo is not empty %}
<div class=\"container-fluid wrapper mt-3\">
<div class=\"col-md-12 mt-1\">
<div class=\"video\">
{% set id_video_externe = post.urlvideo|split('?v=')[1] %}
<a class=\"video-thumbnail m-0\" href=\"{{post.urlvideo}}\" data-fancybox=\"video\">
<img src=\"https://img.youtube.com/vi/{{id_video_externe}}/maxresdefault.jpg\" class=\"img-fluid\" alt=\"\"/>
</a>
</div>
</div>
</div>
{% endif %}
{% if blocs is defined %}
{% for bloc in blocs.Bloc %}
{% if is_mobile() and bloc.mobile == true %}
{{ include ('front/'~ app.request.server.get('APP_THEME') ~'/bloc/bloc.html.twig',{
bloc: bloc,
}, with_context = false)}}
{% endif %}
{% if is_full_view() and is_mobile() == false and bloc.desktop == true %}
{{ include ('front/'~ app.request.server.get('APP_THEME') ~'/bloc/bloc.html.twig',{
bloc: bloc,
}, with_context = false)}}
{% endif %}
{% endfor %}
{% endif %}
</div>
{% endblock %}
{% block javascripts %}
{{parent()}}
<script src=\"{{ asset('assets-admin/plugins/form-builder-io/formio.full.min.js') }}\"></script>
<script src=\"https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js\"></script>
<script>
var current_fs, next_fs, previous_fs;
var left, opacity, scale;
var animating;
\$(\".next\").click(function(){
current_fs = \$(this).parent();
next_fs = \$(this).parent().next();
if (!validateForm(current_fs)) {
return false;
}
if(animating) return false;
animating = true;
\$(\"#progressbar li\").eq(\$(\"fieldset\").index(next_fs)).addClass(\"active\");
next_fs.show();
//hide the current fieldset with style
current_fs.animate({opacity: 0}, {
step: function(now, mx) {
//as the opacity of current_fs reduces to 0 - stored in \"now\"
//1. scale current_fs down to 80%
scale = 1 - (1 - now) * 0.2;
//2. bring next_fs from the right(50%)
left = (now * 50)+\"%\";
//3. increase opacity of next_fs to 1 as it moves in
opacity = 1 - now;
current_fs.css({
'transform': 'scale('+scale+')',
'position': 'absolute'
});
next_fs.css({'left': left, 'opacity': opacity});
},
duration: 1000,
complete: function(){
current_fs.hide();
animating = false;
},
//this comes from the custom easing plugin
easing: 'easeInOutBack'
});
});
\$(\".previous\").click(function(){
current_fs = \$(this).parent();
previous_fs = \$(this).parent().prev();
// if (!validateForm(current_fs)) {
// return false;
// }
if(animating) return false;
animating = true;
//de-activate current step on progressbar
\$(\"#progressbar li\").eq(\$(\"fieldset\").index(current_fs)).removeClass(\"active\");
//show the previous fieldset
previous_fs.show();
//hide the current fieldset with style
previous_fs.css({'transform': 'scale(1)', 'opacity': '1','position':'relative'});
current_fs.hide();
animating = false;
// current_fs.animate({opacity: 0}, {
// step: function(now, mx) {
// //as the opacity of current_fs reduces to 0 - stored in \"now\"
// //1. scale previous_fs from 80% to 100%
// scale = 0.8 + (1 - now) * 0.2;
// //2. take current_fs to the right(50%) - from 0%
// left = ((1-now) * 50)+\"%\";
// //3. increase opacity of previous_fs to 1 as it moves in
// opacity = 1 - now;
// current_fs.css({'left': left});
// previous_fs.css({'transform': 'scale('+scale+')', 'opacity': opacity,'position':'relative'});
// },
// duration: 800,
// complete: function(){
// current_fs.hide();
// animating = false;
// },
// //this comes from the custom easing plugin
// easing: 'easeInOutBack'
// });
});
// \$(\".form-wizrd .submit.action-button\").click(function(e){
// current_fs = \$(this).parent();
// if (!validateForm(current_fs)) {
// return false;
// }
// });
function validateForm(current_fs) {
let formTabs, formInputs, i, valid = true;
formInputs = current_fs[0].querySelectorAll('[data-form-input]');
for (i = 0; i < formInputs.length; i++) {
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') != 'checkbox') {
formInputs[i].addEventListener('keyup', (event) => {
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
// event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') == 'checkbox') {
formInputs[i].addEventListener('change', (event) => {
if(\$(event.target).is(':checked')){
\$(event.target).attr('checked', true);
}else{
\$(event.target).attr('checked', false);
}
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
//event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && formInputs[i].nodeName == 'SELECT') {
formInputs[i].addEventListener('change', (event) => {
console.log('select change');
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
//event.target.nextElementSibling.style.display = \"none\";
});
}
if (formInputs[i].hasAttribute(\"required\") && \$(formInputs[i]).attr('type') == 'email') {
formInputs[i].addEventListener('keyup', (event) => {
console.log(isEmail(event.target.value));
if (isEmail(event.target.value) == true) {
event.target.classList.remove(\"has-error\");
\$(event.target.parentElement).find('.invalid-feedback').css('display','none');
}else{
if (!event.target.classList.contains('has-error')) {
event.target.className += \" has-error\";
}
\$(event.target.parentElement).find('.invalid-feedback').html('Veuillez choisir un email valide.');
\$(event.target.parentElement).find('.invalid-feedback').css('display','block');
}
// event.target.nextElementSibling.style.display = \"none\";
});
}
if(formInputs[i].hasAttribute(\"required\")){
if (\$(formInputs[i]).attr('type') == 'checkbox' && \$(formInputs[i]).is(':checked') == false) {
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}else if(formInputs[i].value == \"\" && (\$(formInputs[i]).attr('type') == 'text' || formInputs[i].nodeName == 'SELECT' || formInputs[i].nodeName == 'TEXTAREA')){
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}else if(!isEmail(formInputs[i].value) && \$(formInputs[i]).attr('type') == 'email'){
if (!formInputs[i].classList.contains('has-error')) {
formInputs[i].className += \" has-error\";
}
\$(formInputs[i].parentElement).find('.invalid-feedback').css('display','block');
valid = false;
}
//formInputs[i].nextElementSibling.style.display = \"block\";
}
}
return valid;
}
function isEmail(email) {
var EmailRegex = /^([a-zA-Z0-9_.+-])+\\@(([a-zA-Z0-9-])+\\.)+([a-zA-Z0-9]{2,4})+\$/;
return EmailRegex.test(email);
}
</script>
<script>
if(document.getElementById(\"builder\")){
var data_fields = document.getElementById(\"builder\").getAttribute('data-config');
if(data_fields != ''){
data_fields = JSON.parse(data_fields);
console.log(JSON.parse(data_fields));
Formio.createForm(document.getElementById('builder'),
JSON.parse(data_fields),
).then(function(form) {
// Prevent the submission from going to the form.io server.
form.nosubmit = true;
// Triggered when they click the submit button.
form.on('submit', function(submission) {
var data = submission.data;
grecaptcha.execute('{{ParametreSite().clekey}}', {action: 'create_comment'}).then(token => {
\$('#builder').find('[name=g-recaptcha-response]').val(token);
data['g-recaptcha-response'] = token;
data['IdForm'] = \$('#builder').parent().find('input[name=\"IdForm\"]').val();
\$('#builder').parent().find('button[type=\"submit\"]').attr('disabled','true');
\$.ajax({
type:\"POST\",
cache:false,
url:\"{{path('save_form')}}\",
data:data,
success: function (data) {
window.location = data
}
});
});
});
});
}
}
</script>
{% if modele_galerie[0].type == 4 %}
{{parent()}}
<script src=\"{{asset('templates/front/theme1/assets/plugins/flexslider/jquery.flexslider.js')}}\" ></script>
<script>
/*-------------------------------------------------*/
/* = Sx flexslider
/*-------------------------------------------------*/
if (\$(\".sx_flexslider\").length) {
\$('.flex-carousel').flexslider({
animation: \"slide\",
controlNav: false,
animationLoop: true,
slideshow: false,
itemWidth: 150,
asNavFor: '.flex-slider'
});
\$('.flex-slider').flexslider({
animation: \"slide\",
controlNav: false,
animationLoop: true,
slideshow: false,
sync: \".flex-carousel\"
});
}
</script>
{% endif %}
{% endblock %}
", "front/theme1/page_ref.html.twig", "/var/www/vhosts/hrz.fr/new-site.hrz.fr/templates/front/theme1/page_ref.html.twig");
}
}