{# </div>#}
<div class="container posts">
<div class="row">
{% for blogNote in blogNotes %}
{% if blogNote.category.type != 'adoptiveBlog' and blogNote.category.type != 'testBlog' %}
{% set postLink = path('base_front_blog_notesingle', {id: blogNote.id}) %}
{% set postDate = blogNote.publishedDate|date("d.m.Y") %}
{% if blogNote.featuredImage %}
{% set postImage = asset(animalImage(blogNote.featuredImage.path)) | imagine_filter('animal_listing_thumb') %}
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["blogNotes"]) || array_key_exists("blogNotes", $context) ? $context["blogNotes"] : (function () { throw new RuntimeError('Variable "blogNotes" does not exist.', 256, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["blogNote"]) {
// line 257
echo " ";
if (((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["blogNote"], "category", [], "any", false, false, false, 257), "type", [], "any", false, false, false, 257) != "adoptiveBlog") && (twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["blogNote"], "category", [], "any", false, false, false, 257), "type", [], "any", false, false, false, 257) != "testBlog"))) {
// line 258
echo " ";
$context["postLink"] = $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("base_front_blog_notesingle", ["id" => twig_get_attribute($this->env, $this->source, $context["blogNote"], "id", [], "any", false, false, false, 258)]);
// line 259
echo " ";
throw new \LogicException('A block must be a method on a \Twig\Template instance.');
}
if (null !== $template) {
try {
$template->$block($context, $blocks);
} catch (Error $e) {
if (!$e->getSourceContext()) {
$e->setSourceContext($template->getSourceContext());
}
$this->displayBlock('menu', $context, $blocks);
// line 163
echo "
";
// line 164
$this->displayBlock('content', $context, $blocks);
// line 166
echo "
";
// line 167
$this->displayBlock('footer', $context, $blocks);
}
protected function displayWithErrorHandling(array $context, array $blocks = [])
{
try {
$this->doDisplay($context, $blocks);
} catch (Error $e) {
if (!$e->getSourceContext()) {
$e->setSourceContext($this->getSourceContext());
}
return $this->blocks;
}
public function display(array $context, array $blocks = [])
{
$this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
}
public function render(array $context)
{
$level = ob_get_level();
// line 7
$context["additionalTitle"] = ("- tag - " . twig_lower_filter($this->env, (isset($context["keyword"]) || array_key_exists("keyword", $context) ? $context["keyword"] : (function () { throw new RuntimeError('Variable "keyword" does not exist.', 7, $this->source); })())));
}
// line 1
$this->parent = $this->loadTemplate("layout/base.html.twig", "front/blog/notes.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
protected function displayWithErrorHandling(array $context, array $blocks = [])
{
try {
$this->doDisplay($context, $blocks);
} catch (Error $e) {
if (!$e->getSourceContext()) {
$e->setSourceContext($this->getSourceContext());
}
return $this->blocks;
}
public function display(array $context, array $blocks = [])
{
$this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
}
public function render(array $context)
{
$level = ob_get_level();
ob_start();
} else {
ob_start(function () { return ''; });
}
try {
$this->display($context);
} catch (\Throwable $e) {
while (ob_get_level() > $level) {
ob_end_clean();
}
public function render(array $context = []): string
{
// using func_get_args() allows to not expose the blocks argument
// as it should only be used by internal code
return $this->template->render($context, \func_get_args()[1] ?? []);
}
public function display(array $context = [])
{
// using func_get_args() allows to not expose the blocks argument
* @throws SyntaxError When an error occurred during compilation
* @throws RuntimeError When an error occurred during rendering
*/
public function render($name, array $context = []): string
{
return $this->load($name)->render($context);
}
/**
* Displays a template.
*
if ($v instanceof FormInterface) {
$parameters[$k] = $v->createView();
}
}
return $this->container->get('twig')->render($view, $parameters);
}
/**
* Renders a view.
*
* If an invalid form is found in the list of parameters, a 422 status code is returned.
* Forms found in parameters are auto-cast to form views.
*/
protected function render(string $view, array $parameters = [], Response $response = null): Response
{
$content = $this->renderView($view, $parameters);
$response ??= new Response();
if (200 === $response->getStatusCode()) {
foreach ($parameters as $v) {
if ($v instanceof FormInterface && $v->isSubmitted() && !$v->isValid()) {
'front/blog/notes.html.twig',
[
'author' => $author,
'anotherAuthors' => $anotherAuthors,
'blogNotes' => $blogNotes,
'blogRotator' => $rotator,
]
);
}
#[Route('/blog', name: 'base_front_blog_notes')]
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
$controller = $event->getController();
$arguments = $event->getArguments();
// call controller
$response = $controller(...$arguments);
// view
if (!$response instanceof Response) {
$event = new ViewEvent($this, $request, $type, $response, $event);
$this->dispatcher->dispatch($event, KernelEvents::VIEW);
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
$this->requestStack->push($request);
try {
return $this->handleRaw($request, $type);
} catch (\Throwable $e) {
if ($e instanceof \Error && !$this->handleAllThrowables) {
throw $e;
}
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
$this->request = $request;
}
public function run(): int
{
$response = $this->kernel->handle($this->request);
$response->send();
if ($this->kernel instanceof TerminableInterface) {
$this->kernel->terminate($this->request, $response);
}
$app = $app(...$args);
exit(
$runtime
->getRunner($app)
->run()
);
<?php
use App\Kernel;
use Symfony\Component\HttpFoundation\Request;
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (array $context) {
$request = Request::createFromGlobals();
if($request->getClientIp() == "95.217.17.2") {
No log messages
RuntimeError
|
---|
Twig\Error\RuntimeError: Neither the property "type" nor one of the methods "type()", "gettype()"/"istype()"/"hastype()" or "__call()" exist and have public access in class "Doctrine\ORM\PersistentCollection". at templates/front/blog/notes.html.twig:257 at twig_get_attribute() (var/cache/dev/twig/40/409c8b7b8f1454bc2bc2f00772faac4a.php:416) at __TwigTemplate_377a6d93a27316d8da3bd287b0e8d9b0->block_content() (vendor/twig/twig/src/Template.php:171) at Twig\Template->displayBlock() (var/cache/dev/twig/8c/8cc468422c78cdd8294f9f789dd1d05f.php:274) at __TwigTemplate_adb3a217e0d6be47c2a966eed217911e->doDisplay() (vendor/twig/twig/src/Template.php:394) at Twig\Template->displayWithErrorHandling() (vendor/twig/twig/src/Template.php:367) at Twig\Template->display() (var/cache/dev/twig/40/409c8b7b8f1454bc2bc2f00772faac4a.php:62) at __TwigTemplate_377a6d93a27316d8da3bd287b0e8d9b0->doDisplay() (vendor/twig/twig/src/Template.php:394) at Twig\Template->displayWithErrorHandling() (vendor/twig/twig/src/Template.php:367) at Twig\Template->display() (vendor/twig/twig/src/Template.php:379) at Twig\Template->render() (vendor/twig/twig/src/TemplateWrapper.php:40) at Twig\TemplateWrapper->render() (vendor/twig/twig/src/Environment.php:280) at Twig\Environment->render() (vendor/symfony/framework-bundle/Controller/AbstractController.php:242) at Symfony\Bundle\FrameworkBundle\Controller\AbstractController->renderView() (vendor/symfony/framework-bundle/Controller/AbstractController.php:253) at Symfony\Bundle\FrameworkBundle\Controller\AbstractController->render() (src/Controller/Front/BlogController.php:67) at App\Controller\Front\BlogController->notesAction() (vendor/symfony/http-kernel/HttpKernel.php:163) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:74) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:184) at Symfony\Component\HttpKernel\Kernel->handle() (vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php:35) at Symfony\Component\Runtime\Runner\Symfony\HttpKernelRunner->run() (vendor/autoload_runtime.php:29) at require_once('/home/adopt/web/adopciaki.pl/public_html/vendor/autoload_runtime.php') (public/index.php:6) |