<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
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;
use Twig\TemplateWrapper;
/* Resources/resource_detail.html.twig */
class __TwigTemplate_bb0a345e6df0a03d4bd4ba5442aa4aca extends Template
{
private Source $source;
/**
* @var array<string, Template>
*/
private array $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
'footer' => [$this, 'block_footer'],
];
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return "layout/layout.html.twig";
}
protected function doDisplay(array $context, array $blocks = []): iterable
{
$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", "Resources/resource_detail.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Resources/resource_detail.html.twig"));
$this->parent = $this->loadTemplate("layout/layout.html.twig", "Resources/resource_detail.html.twig", 1);
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 4
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content(array $context, array $blocks = []): iterable
{
$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", "content"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 5
yield "
<section class=\"resource-banner\">
<div class=\"resource-banner-media\">
<figure class=\"resource-banner-media-img\">
<img src=\"";
// line 9
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 9, $this->source); })()), "resource_banner", [], "any", false, false, false, 9), "html", null, true);
yield "\" alt=\"cooking-banner\">
";
// line 13
yield " </figure>
</div>
</section>
<!-- End banner -->
<!--Start Main training search-->
<section class=\"bread-crumbs-section resources-breadcrumb\">
<div class=\"container container-lg\">
<div class=\"bread-crumbs-section-box\">
<div class=\"breadcrumb-holder\">
<ol class=\"breadcrumb\">
<li class=\"breadcrumb-item\"><a href=\"/";
// line 24
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 24, $this->source); })()), "request", [], "any", false, false, false, 24), "locale", [], "any", false, false, false, 24), "html", null, true);
yield "\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Home"), "html", null, true);
yield "</a></li>
<li class=\"breadcrumb-item\"><a href=\"/";
// line 25
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 25, $this->source); })()), "request", [], "any", false, false, false, 25), "locale", [], "any", false, false, false, 25), "html", null, true);
yield "/resources\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Resources"), "html", null, true);
yield "</a></li>
";
// line 26
if (CoreExtension::getAttribute($this->env, $this->source, ($context["resource"] ?? null), "category", [], "any", true, true, false, 26)) {
// line 27
yield " <li class=\"breadcrumb-item\"><a href=\"/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 27, $this->source); })()), "request", [], "any", false, false, false, 27), "locale", [], "any", false, false, false, 27), "html", null, true);
yield "/resources/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 27, $this->source); })()), "category", [], "any", false, false, false, 27), "url", [], "any", false, false, false, 27), "html", null, true);
yield "\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 27, $this->source); })()), "category", [], "any", false, false, false, 27), "name", [], "any", false, false, false, 27), "html", null, true);
yield "</a></li>
";
}
// line 29
yield " <li class=\"breadcrumb-item\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 29, $this->source); })()), "name", [], "any", false, false, false, 29), "html", null, true);
yield "</li>
</ol>
</div>
</div>
</div>
</section>
<!--End Main training search-->
<div id =\"invoice\">
<!-- Start Article -->
<section class=\"resource-article\">
<div class=\"container container-sm\">
";
// line 41
if ((isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 41, $this->source); })())) {
// line 42
yield " <div class=\"col-12 newsletterBanner-v2\">
<div class=\"row gy-4\">
<div class=\"col-lg-6\">
<h3 class=\"heading\">
";
// line 46
if (((isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 46, $this->source); })()) && !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 46, $this->source); })()), "title", [], "any", false, false, false, 46)))) {
// line 47
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 47, $this->source); })()), "title", [], "any", false, false, false, 47), "html", null, true);
yield "
";
}
// line 49
yield " </h3>
<div class=\"content\">
<div class=\"imgLeft d-md-none\">
";
// line 52
if (((isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 52, $this->source); })()) && !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 52, $this->source); })()), "pdf", [], "any", false, false, false, 52)))) {
// line 53
yield " <a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 53, $this->source); })()), "pdf", [], "any", false, false, false, 53), "html", null, true);
yield "\" target=\"_blank\">
";
// line 54
if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 54, $this->source); })()), "detailImageMobile", [], "any", false, false, false, 54)) {
// line 55
yield " <img src=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 55, $this->source); })()), "detailImageMobile", [], "any", false, false, false, 55), "html", null, true);
yield "\" alt=\"Newsletter-Image-Mobile\">
";
}
// line 56
yield "
</a>
";
}
// line 59
yield "
</div>
<div class=\"contentDesc\">
<p>
";
// line 63
if (((isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 63, $this->source); })()) && !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 63, $this->source); })()), "description", [], "any", false, false, false, 63)))) {
// line 64
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 64, $this->source); })()), "description", [], "any", false, false, false, 64), "html", null, true);
yield "
";
}
// line 66
yield " </p>
";
// line 67
$context["user"] = CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 67, $this->source); })()), "session", [], "any", false, false, false, 67), "get", ["loginUserName"], "method", false, false, false, 67);
// line 68
yield " ";
if ((isset($context["newsletterPdf"]) || array_key_exists("newsletterPdf", $context) ? $context["newsletterPdf"] : (function () { throw new RuntimeError('Variable "newsletterPdf" does not exist.', 68, $this->source); })())) {
// line 69
yield " ";
if ( !(null === (isset($context["user"]) || array_key_exists("user", $context) ? $context["user"] : (function () { throw new RuntimeError('Variable "user" does not exist.', 69, $this->source); })()))) {
// line 70
yield " <a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["newsletterPdf"]) || array_key_exists("newsletterPdf", $context) ? $context["newsletterPdf"] : (function () { throw new RuntimeError('Variable "newsletterPdf" does not exist.', 70, $this->source); })()), "html", null, true);
yield "\" target=\"_blank\" class=\"btn btn-custom btn-lg-o-yellow-white mt-md-5\">
";
// line 71
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Read our Newsletter"), "html", null, true);
yield "
</a>
";
} else {
// line 74
yield " <a href=\"javascript:void(0);\" onclick=\"storePdfForLater('";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["newsletterPdf"]) || array_key_exists("newsletterPdf", $context) ? $context["newsletterPdf"] : (function () { throw new RuntimeError('Variable "newsletterPdf" does not exist.', 74, $this->source); })()), "html", null, true);
yield "')\" class=\"btn btn-custom btn-lg-o-yellow-white mt-md-5\">
";
// line 75
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Read our Newsletter"), "html", null, true);
yield "
</a>
";
}
// line 78
yield " ";
}
// line 79
yield " </div>
</div>
</div>
<div class=\"col-lg-6 d-none d-md-block pt-4 pt-lg-0\">
<div class=\"imgRight\">
";
// line 84
if (((isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 84, $this->source); })()) && !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 84, $this->source); })()), "pdf", [], "any", false, false, false, 84)))) {
// line 85
yield " <a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 85, $this->source); })()), "pdf", [], "any", false, false, false, 85), "html", null, true);
yield "\" class=\"w-100\" target=\"_blank\">
";
// line 86
if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 86, $this->source); })()), "detailImage", [], "any", false, false, false, 86)) {
// line 87
yield " <img src=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["newsletter"]) || array_key_exists("newsletter", $context) ? $context["newsletter"] : (function () { throw new RuntimeError('Variable "newsletter" does not exist.', 87, $this->source); })()), "detailImage", [], "any", false, false, false, 87), "html", null, true);
yield "\" class=\"w-100\" alt=\"Newsletter-Image\">
";
}
// line 88
yield "
</a>
";
}
// line 91
yield " </div>
</div>
</div>
</div>
";
}
// line 96
yield " <div class=\"col-12\">
<div class=\"row justify-content-center mb-5\">
<div class=\"col-12 px-0 d-none\">
";
// line 100
if ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 100, $this->source); })()), "request", [], "any", false, false, false, 100), "locale", [], "any", false, false, false, 100) == "en")) {
// line 101
yield " <a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" class=\"banner-transition-update\">
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-EN.jpg\" alt=\"webinar announcement\">
</a>
";
} else {
// line 105
yield " <a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" class=\"banner-transition-update\">
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-AR.jpg\" alt=\"webinar announcement\">
</a>
";
}
// line 109
yield " </div>
<div class=\"col-12 d-none \">
<a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" >
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-responsive.jpg\" alt=\"webinar announcement responsive\">
</a>
</div>
</div>
</div>
<div class=\"row\">
<div class=\"col-xl-9\">
<div class=\"resource-article-info\">
<h5>";
// line 120
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 120, $this->source); })()), "category", [], "any", false, false, false, 120), "name", [], "any", false, false, false, 120), "html", null, true);
yield "</h5>
<h1 class=\"resource-blog\">";
// line 121
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 121, $this->source); })()), "name", [], "any", false, false, false, 121), "html", null, true);
yield "</h1>
";
// line 122
$context["user"] = CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 122, $this->source); })()), "session", [], "any", false, false, false, 122), "get", ["loginUserName"], "method", false, false, false, 122);
// line 123
yield " ";
if ( !(null === (isset($context["user"]) || array_key_exists("user", $context) ? $context["user"] : (function () { throw new RuntimeError('Variable "user" does not exist.', 123, $this->source); })()))) {
// line 124
yield " <ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this, ";
// line 125
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 125, $this->source); })()), "id", [], "any", false, false, false, 125), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 125, $this->source); })()), "name", [], "any", false, false, false, 125), "html", null, true);
yield "',10,'Article','Share')\"><span onclick = \"sharemodal('Article','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 125, $this->source); })()), "request", [], "any", false, false, false, 125), "getSchemeAndHttpHost", [], "method", false, false, false, 125) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 125, $this->source); })()), "request", [], "any", false, false, false, 125), "locale", [], "any", false, false, false, 125)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 125, $this->source); })()), "url", [], "any", false, false, false, 125)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</span></li>
";
// line 126
if ((Twig\Extension\CoreExtension::length($this->env->getCharset(), (isset($context["Liked_detail_article"]) || array_key_exists("Liked_detail_article", $context) ? $context["Liked_detail_article"] : (function () { throw new RuntimeError('Variable "Liked_detail_article" does not exist.', 126, $this->source); })())) == 0)) {
// line 127
yield " <li class=\"like article-detail\" onclick = \"loyaltyProgram(this, ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 127, $this->source); })()), "id", [], "any", false, false, false, 127), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 127, $this->source); })()), "name", [], "any", false, false, false, 127), "html", null, true);
yield "',10,'Article','Like', '";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 127, $this->source); })()), "request", [], "any", false, false, false, 127), "locale", [], "any", false, false, false, 127), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
} else {
// line 129
yield " <li class= 'liked'>";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
}
// line 132
yield " <li class=\"download-black d-none\" id =\"download\" onclick = \"loyaltyProgram(this, ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 132, $this->source); })()), "id", [], "any", false, false, false, 132), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 132, $this->source); })()), "name", [], "any", false, false, false, 132), "html", null, true);
yield "',10,'Article','Save')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
} else {
// line 135
yield " <ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','";
// line 136
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 136, $this->source); })()), "request", [], "any", false, false, false, 136), "getSchemeAndHttpHost", [], "method", false, false, false, 136) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 136, $this->source); })()), "request", [], "any", false, false, false, 136), "locale", [], "any", false, false, false, 136)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 136, $this->source); })()), "url", [], "any", false, false, false, 136)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</li>
<li class=\"like logged-out\">";
// line 137
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
<li class=\"download-black d-none\" id =\"download\">";
// line 138
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
}
// line 141
yield " <p class=\"resource-article-info-qoute\">";
yield CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 141, $this->source); })()), "main_description", [], "any", false, false, false, 141);
yield "</p>
";
// line 142
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 142, $this->source); })()), "resources", [], "any", false, false, false, 142));
foreach ($context['_seq'] as $context["_key"] => $context["description"]) {
// line 143
yield " ";
if (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 143), "data", [], "any", false, false, false, 143), "getLocalizedValue", ["resource_heading"], "method", false, false, false, 143)) {
// line 144
yield " <h2 class=\"resource-blog\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 144), "data", [], "any", false, false, false, 144), "getLocalizedValue", ["resource_heading"], "method", false, false, false, 144), "html", null, true);
yield "</h2>
";
}
// line 146
yield " <p>";
yield CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 146), "data", [], "any", false, false, false, 146), "getLocalizedValue", ["description"], "method", false, false, false, 146);
yield "</p>
";
// line 147
if (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 147), "data", [], "any", false, false, false, 147), "getLocalizedValue", ["resource_video"], "method", false, false, false, 147)) {
// line 148
yield " <div class=\"media-section\">
<video poster=\"assets/images/media-01.png\">
<source src=\"/static/assets/videos/oceans.mp4\" type=\"video/mp4\">
Your browser does not support the video tag.
</video>
<div class=\"control-options\">
<i class=\"fas fa-play-circle\"></i>
<i class=\"fas fa-pause-circle\"></i>
</div>
</div>
";
}
// line 159
yield " ";
if (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 159), "data", [], "any", false, false, false, 159), "getLocalizedValue", ["resource_image"], "method", false, false, false, 159)) {
// line 160
yield " <div class=\"resource-article-info-media\">
<figure class=\"resource-article-info-media-img\">
<img src=\"";
// line 162
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["description"], "localizedfields", [], "any", false, false, false, 162), "data", [], "any", false, false, false, 162), "getLocalizedValue", ["resource_image"], "method", false, false, false, 162), "html", null, true);
yield "\" alt=\"article-img\">
</figure>
</div>
";
}
// line 166
yield " ";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['description'], $context['_parent']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 167
yield " ";
$context["user"] = CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 167, $this->source); })()), "session", [], "any", false, false, false, 167), "get", ["loginUserName"], "method", false, false, false, 167);
// line 168
yield " ";
if ( !(null === (isset($context["user"]) || array_key_exists("user", $context) ? $context["user"] : (function () { throw new RuntimeError('Variable "user" does not exist.', 168, $this->source); })()))) {
// line 169
yield " <ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this,";
// line 170
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 170, $this->source); })()), "id", [], "any", false, false, false, 170), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 170, $this->source); })()), "name", [], "any", false, false, false, 170), "html", null, true);
yield "',10,'Article','Share')\"><span onclick = \"sharemodal('Article','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 170, $this->source); })()), "request", [], "any", false, false, false, 170), "getSchemeAndHttpHost", [], "method", false, false, false, 170) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 170, $this->source); })()), "request", [], "any", false, false, false, 170), "locale", [], "any", false, false, false, 170)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 170, $this->source); })()), "url", [], "any", false, false, false, 170)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</span></li>
";
// line 171
if ((Twig\Extension\CoreExtension::length($this->env->getCharset(), (isset($context["Liked_detail_article"]) || array_key_exists("Liked_detail_article", $context) ? $context["Liked_detail_article"] : (function () { throw new RuntimeError('Variable "Liked_detail_article" does not exist.', 171, $this->source); })())) == 0)) {
// line 172
yield "
<li class=\"like article-detail\" onclick = \"loyaltyProgram(this,";
// line 173
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 173, $this->source); })()), "id", [], "any", false, false, false, 173), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 173, $this->source); })()), "name", [], "any", false, false, false, 173), "html", null, true);
yield "',10,'Article','Like', '";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 173, $this->source); })()), "request", [], "any", false, false, false, 173), "locale", [], "any", false, false, false, 173), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
} else {
// line 175
yield " <li class= 'liked'>";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
}
// line 178
yield " <li class=\"download-black d-none\" id =\"download\" onclick = \"loyaltyProgram(this,";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 178, $this->source); })()), "id", [], "any", false, false, false, 178), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 178, $this->source); })()), "name", [], "any", false, false, false, 178), "html", null, true);
yield "',10,'Article','Save')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
} else {
// line 181
yield " <ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','";
// line 182
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($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), "getSchemeAndHttpHost", [], "method", false, false, false, 182) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($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), "locale", [], "any", false, false, false, 182)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 182, $this->source); })()), "url", [], "any", false, false, false, 182)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</li>
<li class=\"like logged-out\">";
// line 183
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
<li class=\"download-black d-none\" id =\"download\">";
// line 184
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
}
// line 187
yield "
";
// line 204
yield "
</div>
</div>
<div class=\"col-xl-3\">
<div class=\"resource-article-related\">
<!--Start Featured Recipes Section-->
<section class=\"featured-recipes-section inner-frecipes-section all-event-section related-article-section\">
<div class=\"container container-sm\">
<h2 class=\"heading related-article-headingg\">";
// line 212
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Related Articles"), "html", null, true);
yield "</h2>
<div class=\"featured-recipes\">
<div class=\"custom-slider\">
";
// line 215
if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 215, $this->source); })()), "related_article", [], "any", false, false, false, 215)) {
// line 216
yield " ";
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 216, $this->source); })()), "related_article", [], "any", false, false, false, 216));
foreach ($context['_seq'] as $context["_key"] => $context["article"]) {
// line 217
yield " <div class=\"slide-holder\">
<div class=\"slide-holder\">
<a href=\"/";
// line 219
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 219, $this->source); })()), "request", [], "any", false, false, false, 219), "locale", [], "any", false, false, false, 219), "html", null, true);
yield "/resource/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "url", [], "any", false, false, false, 219), "html", null, true);
yield "\">
<figure class=\"slide-img\">
<img src=\"";
// line 221
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "image", [], "any", false, false, false, 221), "html", null, true);
yield "\" alt=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "name", [], "any", false, false, false, 221), "html", null, true);
yield "\">
</figure><a/>
<div class=\"slide-content\">
<div class=\"frecipes-box\">
<a href=\"/";
// line 225
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 225, $this->source); })()), "request", [], "any", false, false, false, 225), "locale", [], "any", false, false, false, 225), "html", null, true);
yield "/resource/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "url", [], "any", false, false, false, 225), "html", null, true);
yield "\" class=\"text-decoration-none\"><h3>";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "name", [], "any", false, false, false, 225), "html", null, true);
yield "</h3></a>
<p>";
// line 226
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "main_description", [], "any", false, false, false, 226), "html", null, true);
yield "</p>
</div>
";
// line 228
$context["user"] = CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 228, $this->source); })()), "session", [], "any", false, false, false, 228), "get", ["loginUserName"], "method", false, false, false, 228);
// line 229
yield " ";
if ( !(null === (isset($context["user"]) || array_key_exists("user", $context) ? $context["user"] : (function () { throw new RuntimeError('Variable "user" does not exist.', 229, $this->source); })()))) {
yield "
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this,";
// line 231
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "id", [], "any", false, false, false, 231), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "name", [], "any", false, false, false, 231), "html", null, true);
yield "',10,'Article','Share')\"><span onclick = \"sharemodal('Article','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 231, $this->source); })()), "request", [], "any", false, false, false, 231), "getSchemeAndHttpHost", [], "method", false, false, false, 231) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 231, $this->source); })()), "request", [], "any", false, false, false, 231), "locale", [], "any", false, false, false, 231)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, $context["article"], "url", [], "any", false, false, false, 231)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</span></li>
";
// line 232
if (CoreExtension::inFilter(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "id", [], "any", false, false, false, 232), (isset($context["Liked_related_article_Ids"]) || array_key_exists("Liked_related_article_Ids", $context) ? $context["Liked_related_article_Ids"] : (function () { throw new RuntimeError('Variable "Liked_related_article_Ids" does not exist.', 232, $this->source); })()))) {
// line 233
yield " <li class= 'liked'>";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
} else {
// line 235
yield " <li class=\"like related_article\" onclick = \"loyaltyProgram(this,";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "id", [], "any", false, false, false, 235), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "name", [], "any", false, false, false, 235), "html", null, true);
yield "',10,'Article','Like', '";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 235, $this->source); })()), "request", [], "any", false, false, false, 235), "locale", [], "any", false, false, false, 235), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
";
}
// line 238
yield "
<li class=\"download-black d-none\" onclick = \"loyaltyProgram(this,";
// line 239
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "id", [], "any", false, false, false, 239), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["article"], "name", [], "any", false, false, false, 239), "html", null, true);
yield "',10,'Article','Save')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
} else {
// line 242
yield " <ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','";
// line 243
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 243, $this->source); })()), "request", [], "any", false, false, false, 243), "getSchemeAndHttpHost", [], "method", false, false, false, 243) . "/") . CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 243, $this->source); })()), "request", [], "any", false, false, false, 243), "locale", [], "any", false, false, false, 243)) . "/resource/") . CoreExtension::getAttribute($this->env, $this->source, $context["article"], "url", [], "any", false, false, false, 243)), "html", null, true);
yield "','";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("SHARE KNOWLEDGE WITH YOUR FRIENDS"), "html", null, true);
yield "')\">";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Share"), "html", null, true);
yield "</li>
<li class=\"like logged-out\" >";
// line 244
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Like"), "html", null, true);
yield "</li>
<li class=\"download-black d-none\" >";
// line 245
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Download"), "html", null, true);
yield "</li>
</ul>
";
}
// line 248
yield " </div>
</div>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['article'], $context['_parent']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 252
yield " ";
} else {
// line 253
yield " No Related Article
";
}
// line 255
yield " </div>
</div>
</div>
</section>
<!--End Featured Recipes Section-->
</div>
</div>
</div>
</div>
</section>
<!-- End Article -->
</div>
<!--Start Category Section -->
<section class=\"featured-categories resource-featured-categories\">
<div class=\"container container-sm\">
<div class=\"featured-categories-section\">
<h2 class=\"heading\">";
// line 271
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("More Topics"), "html", null, true);
yield "</h2>
<div class=\"featured-categories-section-wrapper\">
";
// line 273
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable((isset($context["more_topics"]) || array_key_exists("more_topics", $context) ? $context["more_topics"] : (function () { throw new RuntimeError('Variable "more_topics" does not exist.', 273, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["topic"]) {
// line 274
yield " <div class=\"featured-categories-section-wrapper-item\">
<a href=\"/";
// line 275
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 275, $this->source); })()), "request", [], "any", false, false, false, 275), "locale", [], "any", false, false, false, 275), "html", null, true);
yield "/resources/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "url", [], "any", false, false, false, 275), "html", null, true);
yield "\">
<figure class=\"featured-categories-section-wrapper-item-video\">
<div class=\"media-section\">
<video poster=\"";
// line 278
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "image", [], "any", false, false, false, 278), "html", null, true);
yield "\" playsinline>
";
// line 279
if (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "video", [], "any", false, true, false, 279), "data", [], "any", true, true, false, 279)) {
yield "
<source src=\"";
// line 280
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "video", [], "any", false, false, false, 280), "data", [], "any", false, false, false, 280), "html", null, true);
yield "\" type=\"video/mp4\">
";
}
// line 282
yield " Your browser does not support the video tag.
</video>
";
// line 288
yield " </div>
</figure></a>
<div class=\"featured-categories-section-wrapper-item-content\">
<a href=\"/";
// line 291
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 291, $this->source); })()), "request", [], "any", false, false, false, 291), "locale", [], "any", false, false, false, 291), "html", null, true);
yield "/resources/";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "url", [], "any", false, false, false, 291), "html", null, true);
yield "\" class=\"featured-categories-section-wrapper-item-content-btn\">
";
// line 292
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["topic"], "name", [], "any", false, false, false, 292), "html", null, true);
yield "
</a>
</div>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['topic'], $context['_parent']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 298
yield " </div>
</div>
</div>
</section>
<!--End Category Section -->
";
// line 303
if ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 303, $this->source); })()), "request", [], "any", false, false, false, 303), "locale", [], "any", false, false, false, 303) == "ar")) {
// line 304
yield " ";
$context["topMenu"] = ("/en/resource/" . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 304, $this->source); })()), "url", ["en"], "method", false, false, false, 304));
// line 305
yield " ";
} else {
// line 306
yield " ";
$context["topMenu"] = ("/ar/resource/" . CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 306, $this->source); })()), "url", ["en"], "method", false, false, false, 306));
// line 307
yield " ";
}
// line 308
yield " <script>
var _TopMenuLink = \"";
// line 309
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["topMenu"]) || array_key_exists("topMenu", $context) ? $context["topMenu"] : (function () { throw new RuntimeError('Variable "topMenu" does not exist.', 309, $this->source); })()), "html", null, true);
yield "\";
\$(document).ready(function(){
//loyaltyProgram(this,";
// line 311
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 311, $this->source); })()), "id", [], "any", false, false, false, 311), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 311, $this->source); })()), "name", [], "any", false, false, false, 311), "html", null, true);
yield "',50,'Article','Viewed')
});
";
// line 322
yield "
</script>
<script type=\"text/javascript\">
// This code is Vanilla JS, you can equivalently use jQuery
// \$(document).ready() or \$(window).on()
let timeSpentScrolling = 0;
let isHalted = false;
let haltedStartTime, haltedEndTime;
let totalHaltedTime = 0;
const update_halt_state = () => {
if (isHalted) {
isHalted = false;
haltedEndTime = new Date().getTime()
totalHaltedTime += (haltedEndTime - haltedStartTime) / 1000
} else {
isHalted = true;
haltedStartTime = new Date().getTime()
}
}
// Listen for scroll events
window.addEventListener('scroll', () => {
timeSpentScrolling += 1.8;
update_halt_state()
});
document.addEventListener(\"DOMContentLoaded\", () => {
const start = new Date().getTime();
// AVERAGE SCROLLING INTERVAL - 60 seconds
setInterval(() => {
if (new Date().getTime() - start > 60000) {
update_halt_state()
\$(document).ready(function(){
loyaltyProgram(this,";
// line 363
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 363, $this->source); })()), "id", [], "any", false, false, false, 363), "html", null, true);
yield ",'";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["resource"]) || array_key_exists("resource", $context) ? $context["resource"] : (function () { throw new RuntimeError('Variable "resource" does not exist.', 363, $this->source); })()), "name", [], "any", false, false, false, 363), "html", null, true);
yield "',50,'Article','Viewed')
});
}
}, 39000)
window.addEventListener(\"beforeunload\", () => {
const end = new Date().getTime();
update_halt_state()
const totalTime = ((end - start) / 1000) - (timeSpentScrolling / 1000) - totalHaltedTime
//navigator.sendBeacon(\"https://topapi2.free.beeceptor.com\", totalTime)
});
});
</script>
<!-- Resource Listing More Topics End -->
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 381
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_footer(array $context, array $blocks = []): iterable
{
$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", "footer"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "footer"));
// line 382
yield " ";
yield from $this->loadTemplate("includes/footer.html.twig", "Resources/resource_detail.html.twig", 382)->unwrap()->yield($context);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "Resources/resource_detail.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 864 => 382, 851 => 381, 820 => 363, 777 => 322, 770 => 311, 765 => 309, 762 => 308, 759 => 307, 756 => 306, 753 => 305, 750 => 304, 748 => 303, 741 => 298, 729 => 292, 723 => 291, 718 => 288, 714 => 282, 709 => 280, 705 => 279, 701 => 278, 693 => 275, 690 => 274, 686 => 273, 681 => 271, 663 => 255, 659 => 253, 656 => 252, 647 => 248, 641 => 245, 637 => 244, 629 => 243, 626 => 242, 616 => 239, 613 => 238, 600 => 235, 594 => 233, 592 => 232, 580 => 231, 574 => 229, 572 => 228, 567 => 226, 559 => 225, 550 => 221, 543 => 219, 539 => 217, 534 => 216, 532 => 215, 526 => 212, 516 => 204, 513 => 187, 507 => 184, 503 => 183, 495 => 182, 492 => 181, 481 => 178, 474 => 175, 463 => 173, 460 => 172, 458 => 171, 446 => 170, 443 => 169, 440 => 168, 437 => 167, 431 => 166, 424 => 162, 420 => 160, 417 => 159, 404 => 148, 402 => 147, 397 => 146, 391 => 144, 388 => 143, 384 => 142, 379 => 141, 373 => 138, 369 => 137, 361 => 136, 358 => 135, 347 => 132, 340 => 129, 328 => 127, 326 => 126, 314 => 125, 311 => 124, 308 => 123, 306 => 122, 302 => 121, 298 => 120, 285 => 109, 279 => 105, 273 => 101, 271 => 100, 265 => 96, 258 => 91, 253 => 88, 247 => 87, 245 => 86, 240 => 85, 238 => 84, 231 => 79, 228 => 78, 222 => 75, 217 => 74, 211 => 71, 206 => 70, 203 => 69, 200 => 68, 198 => 67, 195 => 66, 189 => 64, 187 => 63, 181 => 59, 176 => 56, 170 => 55, 168 => 54, 163 => 53, 161 => 52, 156 => 49, 150 => 47, 148 => 46, 142 => 42, 140 => 41, 124 => 29, 114 => 27, 112 => 26, 106 => 25, 100 => 24, 87 => 13, 83 => 9, 77 => 5, 64 => 4, 41 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends \"layout/layout.html.twig\" %}
{# {% block title %}GFS - {{resource.name}}{% endblock %} #}
{% block content %}
<section class=\"resource-banner\">
<div class=\"resource-banner-media\">
<figure class=\"resource-banner-media-img\">
<img src=\"{{resource.resource_banner}}\" alt=\"cooking-banner\">
{# {% if resource.resource_banner %}
{{ resource.resource_banner.thumbnail('1903x1070').getHTML({imgAttributes: {class:'',alt: \"cooking-banner\"}}) | raw }}
{% endif %} #}
</figure>
</div>
</section>
<!-- End banner -->
<!--Start Main training search-->
<section class=\"bread-crumbs-section resources-breadcrumb\">
<div class=\"container container-lg\">
<div class=\"bread-crumbs-section-box\">
<div class=\"breadcrumb-holder\">
<ol class=\"breadcrumb\">
<li class=\"breadcrumb-item\"><a href=\"/{{app.request.locale}}\">{{'Home'|trans}}</a></li>
<li class=\"breadcrumb-item\"><a href=\"/{{app.request.locale}}/resources\">{{'Resources'|trans}}</a></li>
{% if resource.category is defined %}
<li class=\"breadcrumb-item\"><a href=\"/{{app.request.locale}}/resources/{{resource.category.url}}\">{{resource.category.name}}</a></li>
{% endif %}
<li class=\"breadcrumb-item\">{{resource.name}}</li>
</ol>
</div>
</div>
</div>
</section>
<!--End Main training search-->
<div id =\"invoice\">
<!-- Start Article -->
<section class=\"resource-article\">
<div class=\"container container-sm\">
{% if newsletter %}
<div class=\"col-12 newsletterBanner-v2\">
<div class=\"row gy-4\">
<div class=\"col-lg-6\">
<h3 class=\"heading\">
{% if newsletter and newsletter.title is not null %}
{{newsletter.title}}
{% endif %}
</h3>
<div class=\"content\">
<div class=\"imgLeft d-md-none\">
{% if newsletter and newsletter.pdf is not null %}
<a href=\"{{newsletter.pdf}}\" target=\"_blank\">
{% if newsletter.detailImageMobile %}
<img src=\"{{newsletter.detailImageMobile}}\" alt=\"Newsletter-Image-Mobile\">
{% endif %}
</a>
{% endif %}
</div>
<div class=\"contentDesc\">
<p>
{% if newsletter and newsletter.description is not null %}
{{newsletter.description}}
{% endif %}
</p>
{% set user = app.session.get('loginUserName') %}
{% if newsletterPdf %}
{% if user is not null %}
<a href=\"{{newsletterPdf}}\" target=\"_blank\" class=\"btn btn-custom btn-lg-o-yellow-white mt-md-5\">
{{\"Read our Newsletter\" | trans}}
</a>
{% else %}
<a href=\"javascript:void(0);\" onclick=\"storePdfForLater('{{ newsletterPdf }}')\" class=\"btn btn-custom btn-lg-o-yellow-white mt-md-5\">
{{\"Read our Newsletter\" | trans}}
</a>
{% endif %}
{% endif %}
</div>
</div>
</div>
<div class=\"col-lg-6 d-none d-md-block pt-4 pt-lg-0\">
<div class=\"imgRight\">
{% if newsletter and newsletter.pdf is not null %}
<a href=\"{{newsletter.pdf}}\" class=\"w-100\" target=\"_blank\">
{% if newsletter.detailImage %}
<img src=\"{{newsletter.detailImage}}\" class=\"w-100\" alt=\"Newsletter-Image\">
{% endif %}
</a>
{% endif %}
</div>
</div>
</div>
</div>
{% endif %}
<div class=\"col-12\">
<div class=\"row justify-content-center mb-5\">
<div class=\"col-12 px-0 d-none\">
{% if (app.request.locale =='en') %}
<a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" class=\"banner-transition-update\">
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-EN.jpg\" alt=\"webinar announcement\">
</a>
{% else %}
<a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" class=\"banner-transition-update\">
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-AR.jpg\" alt=\"webinar announcement\">
</a>
{% endif %}
</div>
<div class=\"col-12 d-none \">
<a href=\"https://zoom.us/webinar/register/6417301077993/WN_Uy4Xiz0OT2SuJn0cCsaSUQ\" >
<img class=\"img-fluid w-100\" src=\"/resourcebanner/webinar-announcement-responsive.jpg\" alt=\"webinar announcement responsive\">
</a>
</div>
</div>
</div>
<div class=\"row\">
<div class=\"col-xl-9\">
<div class=\"resource-article-info\">
<h5>{{resource.category.name}}</h5>
<h1 class=\"resource-blog\">{{resource.name}}</h1>
{% set user = app.session.get('loginUserName') %}
{% if user is not null %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this, {{ resource.id }},'{{ resource.name }}',10,'Article','Share')\"><span onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ resource.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</span></li>
{% if Liked_detail_article|length == 0 %}
<li class=\"like article-detail\" onclick = \"loyaltyProgram(this, {{ resource.id }},'{{ resource.name }}',10,'Article','Like', '{{app.request.locale}}')\">{{'Like'|trans}}</li>
{% else %}
<li class= 'liked'>{{'Like'|trans}}</li>
{% endif %}
<li class=\"download-black d-none\" id =\"download\" onclick = \"loyaltyProgram(this, {{ resource.id }},'{{ resource.name }}',10,'Article','Save')\">{{'Download'|trans}}</li>
</ul>
{% else %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ resource.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</li>
<li class=\"like logged-out\">{{'Like'|trans}}</li>
<li class=\"download-black d-none\" id =\"download\">{{'Download'|trans}}</li>
</ul>
{% endif %}
<p class=\"resource-article-info-qoute\">{{resource.main_description | raw}}</p>
{% for description in resource.resources %}
{% if description.localizedfields.data.getLocalizedValue('resource_heading') %}
<h2 class=\"resource-blog\">{{description.localizedfields.data.getLocalizedValue('resource_heading')}}</h2>
{% endif %}
<p>{{description.localizedfields.data.getLocalizedValue('description')|raw}}</p>
{% if description.localizedfields.data.getLocalizedValue('resource_video') %}
<div class=\"media-section\">
<video poster=\"assets/images/media-01.png\">
<source src=\"/static/assets/videos/oceans.mp4\" type=\"video/mp4\">
Your browser does not support the video tag.
</video>
<div class=\"control-options\">
<i class=\"fas fa-play-circle\"></i>
<i class=\"fas fa-pause-circle\"></i>
</div>
</div>
{% endif %}
{% if description.localizedfields.data.getLocalizedValue('resource_image') %}
<div class=\"resource-article-info-media\">
<figure class=\"resource-article-info-media-img\">
<img src=\"{{description.localizedfields.data.getLocalizedValue('resource_image')}}\" alt=\"article-img\">
</figure>
</div>
{% endif %}
{% endfor %}
{% set user = app.session.get('loginUserName') %}
{% if user is not null %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this,{{ resource.id }},'{{ resource.name }}',10,'Article','Share')\"><span onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ resource.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</span></li>
{% if Liked_detail_article|length == 0 %}
<li class=\"like article-detail\" onclick = \"loyaltyProgram(this,{{ resource.id }},'{{ resource.name }}',10,'Article','Like', '{{app.request.locale}}')\">{{'Like'|trans}}</li>
{% else %}
<li class= 'liked'>{{'Like'|trans}}</li>
{% endif %}
<li class=\"download-black d-none\" id =\"download\" onclick = \"loyaltyProgram(this,{{ resource.id }},'{{ resource.name }}',10,'Article','Save')\">{{'Download'|trans}}</li>
</ul>
{% else %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ resource.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</li>
<li class=\"like logged-out\">{{'Like'|trans}}</li>
<li class=\"download-black d-none\" id =\"download\">{{'Download'|trans}}</li>
</ul>
{% endif %}
{# <div class = \"refrances\">
{% if resource.references_links %}
<div class = \"refrances-links\">
<h3>{{'References'|trans}}</h3>
<ul class=\"list-unstyled\">
{% for refrences in resource.references_links %}
<li><a href = \"{{refrences.references.data}}\">{{refrences.references.data}}</a></li>
{% endfor %}
</ul>
</div>
{% endif %}
</div> #}
</div>
</div>
<div class=\"col-xl-3\">
<div class=\"resource-article-related\">
<!--Start Featured Recipes Section-->
<section class=\"featured-recipes-section inner-frecipes-section all-event-section related-article-section\">
<div class=\"container container-sm\">
<h2 class=\"heading related-article-headingg\">{{'Related Articles'|trans}}</h2>
<div class=\"featured-recipes\">
<div class=\"custom-slider\">
{% if resource.related_article %}
{% for article in resource.related_article %}
<div class=\"slide-holder\">
<div class=\"slide-holder\">
<a href=\"/{{app.request.locale}}/resource/{{article.url}}\">
<figure class=\"slide-img\">
<img src=\"{{article.image}}\" alt=\"{{ article.name }}\">
</figure><a/>
<div class=\"slide-content\">
<div class=\"frecipes-box\">
<a href=\"/{{app.request.locale}}/resource/{{article.url}}\" class=\"text-decoration-none\"><h3>{{article.name}}</h3></a>
<p>{{article.main_description}}</p>
</div>
{% set user = app.session.get('loginUserName') %}
{% if user is not null %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"loyaltyProgram(this,{{ article.id }},'{{ article.name }}',10,'Article','Share')\"><span onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ article.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</span></li>
{% if article.id in Liked_related_article_Ids %}
<li class= 'liked'>{{'Like'|trans}}</li>
{% else %}
<li class=\"like related_article\" onclick = \"loyaltyProgram(this,{{ article.id }},'{{ article.name }}',10,'Article','Like', '{{app.request.locale}}')\">{{'Like'|trans}}</li>
{% endif %}
<li class=\"download-black d-none\" onclick = \"loyaltyProgram(this,{{ article.id }},'{{ article.name }}',10,'Article','Save')\">{{'Download'|trans}}</li>
</ul>
{% else %}
<ul class=\"list-unstyled recipe-info\">
<li class=\"share\" onclick = \"sharemodal('Article','{{ app.request.getSchemeAndHttpHost() ~ '/' ~ app.request.locale ~ '/resource/' ~ article.url}}','{{ \"SHARE KNOWLEDGE WITH YOUR FRIENDS\"|trans }}')\">{{'Share'|trans}}</li>
<li class=\"like logged-out\" >{{'Like'|trans}}</li>
<li class=\"download-black d-none\" >{{'Download'|trans}}</li>
</ul>
{% endif %}
</div>
</div>
</div>
{% endfor %}
{% else %}
No Related Article
{% endif %}
</div>
</div>
</div>
</section>
<!--End Featured Recipes Section-->
</div>
</div>
</div>
</div>
</section>
<!-- End Article -->
</div>
<!--Start Category Section -->
<section class=\"featured-categories resource-featured-categories\">
<div class=\"container container-sm\">
<div class=\"featured-categories-section\">
<h2 class=\"heading\">{{'More Topics'|trans}}</h2>
<div class=\"featured-categories-section-wrapper\">
{% for topic in more_topics %}
<div class=\"featured-categories-section-wrapper-item\">
<a href=\"/{{app.request.locale}}/resources/{{topic.url}}\">
<figure class=\"featured-categories-section-wrapper-item-video\">
<div class=\"media-section\">
<video poster=\"{{topic.image}}\" playsinline>
{% if topic.video.data is defined %}
<source src=\"{{ topic.video.data }}\" type=\"video/mp4\">
{% endif %}
Your browser does not support the video tag.
</video>
{# <div class=\"control-options\">
<i class=\"fas fa-play-circle\"></i>
<i class=\"fas fa-pause-circle\"></i>
</div> #}
</div>
</figure></a>
<div class=\"featured-categories-section-wrapper-item-content\">
<a href=\"/{{app.request.locale}}/resources/{{topic.url}}\" class=\"featured-categories-section-wrapper-item-content-btn\">
{{topic.name}}
</a>
</div>
</div>
{% endfor %}
</div>
</div>
</div>
</section>
<!--End Category Section -->
{% if (app.request.locale =='ar') %}
{% set topMenu =\"/en/resource/\" ~ resource.url('en') %}
{% else %}
{% set topMenu =\"/ar/resource/\" ~ resource.url('en') %}
{% endif %}
<script>
var _TopMenuLink = \"{{ topMenu }}\";
\$(document).ready(function(){
//loyaltyProgram(this,{{ resource.id }},'{{ resource.name }}',50,'Article','Viewed')
});
{# document.addEventListener(\"DOMContentLoaded\", () => {
const start = new Date().getTime();
window.addEventListener(\"beforeunload\", () => {
const end = new Date().getTime();
const totalTime = (end - start) / 1000
\t
console.log(totalTime)
});
}); #}
</script>
<script type=\"text/javascript\">
// This code is Vanilla JS, you can equivalently use jQuery
// \$(document).ready() or \$(window).on()
let timeSpentScrolling = 0;
let isHalted = false;
let haltedStartTime, haltedEndTime;
let totalHaltedTime = 0;
const update_halt_state = () => {
if (isHalted) {
isHalted = false;
haltedEndTime = new Date().getTime()
totalHaltedTime += (haltedEndTime - haltedStartTime) / 1000
} else {
isHalted = true;
haltedStartTime = new Date().getTime()
}
}
// Listen for scroll events
window.addEventListener('scroll', () => {
timeSpentScrolling += 1.8;
update_halt_state()
});
document.addEventListener(\"DOMContentLoaded\", () => {
const start = new Date().getTime();
// AVERAGE SCROLLING INTERVAL - 60 seconds
setInterval(() => {
if (new Date().getTime() - start > 60000) {
update_halt_state()
\$(document).ready(function(){
loyaltyProgram(this,{{ resource.id }},'{{ resource.name }}',50,'Article','Viewed')
});
}
}, 39000)
window.addEventListener(\"beforeunload\", () => {
const end = new Date().getTime();
update_halt_state()
const totalTime = ((end - start) / 1000) - (timeSpentScrolling / 1000) - totalHaltedTime
//navigator.sendBeacon(\"https://topapi2.free.beeceptor.com\", totalTime)
});
});
</script>
<!-- Resource Listing More Topics End -->
{% endblock %}
{% block footer %}
{% include \"includes/footer.html.twig\" %}
{% endblock %}
", "Resources/resource_detail.html.twig", "/var/www/vhosts/centric.ae/gcs.centric.ae/templates/Resources/resource_detail.html.twig");
}
}