<?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;
/* question/homepage.html.twig */
class __TwigTemplate_ecc1337b8feb95f329bc94c0f70160b5 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'body' => [$this, 'block_body'],
];
}
protected function doGetParent(array $context)
{
// line 1
return "base.html.twig";
}
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", "question/homepage.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "question/homepage.html.twig"));
$this->parent = $this->loadTemplate("base.html.twig", "question/homepage.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
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 4
echo "<div class=\"jumbotron-img p-2 mb-2\">
<div class=\"container\">
<h1 class=\"display-4\">Your Questions Answered</h1>
<div class=\"lead\">And even answers for those questions you didn't think to ask!</div>
</div>
</div>
<div class=\"container\">
<div class=\"row mb-3\">
<div class=\"col\">
<button class=\"btn btn-question\">Ask a Question</button>
</div>
</div>
<div class=\"row\">
";
// line 17
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["questions"]) || array_key_exists("questions", $context) ? $context["questions"] : (function () { throw new RuntimeError('Variable "questions" does not exist.', 17, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["question"]) {
// line 18
echo " <div class=\"col-12 mb-3\">
<div style=\"box-shadow: 2px 3px 9px 4px rgba(0,0,0,0.04);\">
<div class=\"q-container p-4\">
<div class=\"row\">
<div class=\"col-2 text-center\">
<img src=\"";
// line 23
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["question"], "askedBy", [], "any", false, false, false, 23), "avatarUrl", [], "any", false, false, false, 23)), "html", null, true);
echo "\" width=\"100\" height=\"100\" alt=\"Tisha avatar\">
<div class=\"vote-arrows vote-arrows-alt flex-fill pt-2\" style=\"min-width: 90px;\">
<span>";
// line 25
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["question"], "votesString", [], "any", false, false, false, 25), "html", null, true);
echo " votes</span>
</div>
</div>
<div class=\"col\">
<a class=\"q-title\" href=\"";
// line 29
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_question_show", ["slug" => twig_get_attribute($this->env, $this->source, $context["question"], "slug", [], "any", false, false, false, 29)]), "html", null, true);
echo "\"><h2>";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["question"], "name", [], "any", false, false, false, 29), "html", null, true);
echo "</h2></a>
<div class=\"q-display p-3\">
<i class=\"fa fa-quote-left mr-3\"></i>
<p class=\"d-inline\">";
// line 32
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["question"], "question", [], "any", false, false, false, 32), "html", null, true);
echo "</p>
<p class=\"pt-4\"><strong>--";
// line 33
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["question"], "askedBy", [], "any", false, false, false, 33), "fullName", [], "any", false, false, false, 33), "html", null, true);
echo "</strong></p>
</div>
</div>
</div>
</div>
<a class=\"answer-link\" href=\"";
// line 38
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_question_show", ["slug" => twig_get_attribute($this->env, $this->source, $context["question"], "slug", [], "any", false, false, false, 38)]), "html", null, true);
echo "\" style=\"color: #fff;\">
<p class=\"q-display-response text-center p-3\">
<i class=\"fa fa-magic magic-wand\"></i> ";
// line 40
echo twig_escape_filter($this->env, twig_length_filter($this->env, twig_get_attribute($this->env, $this->source, $context["question"], "answers", [], "any", false, false, false, 40)), "html", null, true);
echo " answers
</p>
</a>
</div>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['question'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 46
echo " </div>
</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName()
{
return "question/homepage.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable()
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo()
{
return array ( 143 => 46, 131 => 40, 126 => 38, 118 => 33, 114 => 32, 106 => 29, 99 => 25, 94 => 23, 87 => 18, 83 => 17, 68 => 4, 58 => 3, 35 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'base.html.twig' %}
{% block body %}
<div class=\"jumbotron-img p-2 mb-2\">
<div class=\"container\">
<h1 class=\"display-4\">Your Questions Answered</h1>
<div class=\"lead\">And even answers for those questions you didn't think to ask!</div>
</div>
</div>
<div class=\"container\">
<div class=\"row mb-3\">
<div class=\"col\">
<button class=\"btn btn-question\">Ask a Question</button>
</div>
</div>
<div class=\"row\">
{% for question in questions %}
<div class=\"col-12 mb-3\">
<div style=\"box-shadow: 2px 3px 9px 4px rgba(0,0,0,0.04);\">
<div class=\"q-container p-4\">
<div class=\"row\">
<div class=\"col-2 text-center\">
<img src=\"{{ asset(question.askedBy.avatarUrl) }}\" width=\"100\" height=\"100\" alt=\"Tisha avatar\">
<div class=\"vote-arrows vote-arrows-alt flex-fill pt-2\" style=\"min-width: 90px;\">
<span>{{ question.votesString}} votes</span>
</div>
</div>
<div class=\"col\">
<a class=\"q-title\" href=\"{{ path('app_question_show', { slug: question.slug }) }}\"><h2>{{ question.name }}</h2></a>
<div class=\"q-display p-3\">
<i class=\"fa fa-quote-left mr-3\"></i>
<p class=\"d-inline\">{{ question.question }}</p>
<p class=\"pt-4\"><strong>--{{ question.askedBy.fullName }}</strong></p>
</div>
</div>
</div>
</div>
<a class=\"answer-link\" href=\"{{ path('app_question_show', { slug: question.slug }) }}\" style=\"color: #fff;\">
<p class=\"q-display-response text-center p-3\">
<i class=\"fa fa-magic magic-wand\"></i> {{ question.answers|length }} answers
</p>
</a>
</div>
</div>
{% endfor %}
</div>
</div>
{% endblock %}
", "question/homepage.html.twig", "/home/u538818725/domains/growupcrypto.site/public_html/templates/question/homepage.html.twig");
}
}