Choose your language
This is a demo application built in the Symfony Framework to illustrate the recommended way of developing Symfony applications.
For more information, check out the Symfony doc.
Click on this button to show the source code of the Controller and template used to render this page.
src/Controller/BlogController.php at line 165
#[Route('/search', name: 'blog_search', methods: ['GET'])] public function search(Request $request): Response { return $this->render('blog/search.html.twig', ['query' => (string) $request->query->get('q', '')]); }
templates/blog/search.html.twig at line 1
{% extends 'base.html.twig' %} {% block body_id 'blog_search' %} {% block main %} {# Render a component by passing its name as first argument See https://symfony.com/bundles/ux-twig-component/current/index.html #} {{ component('blog_search', { query: query }) }} {% endblock %} {% block sidebar %} {{ parent() }} {{ show_source_code(_self) }} {% endblock %}