parent
5cf337fd9d
commit
6d3f601461
@ -1,18 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Controller;
|
|
||||||
|
|
||||||
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
|
||||||
use Symfony\Component\HttpFoundation\Response;
|
|
||||||
use Symfony\Component\Routing\Attribute\Route;
|
|
||||||
|
|
||||||
class SpeciesController extends AbstractController
|
|
||||||
{
|
|
||||||
#[Route('/species', name: 'app_species')]
|
|
||||||
public function index(): Response
|
|
||||||
{
|
|
||||||
return $this->render('species/index.html.twig', [
|
|
||||||
'controller_name' => 'SpeciesController',
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,20 +0,0 @@
|
|||||||
{% extends 'base.html.twig' %}
|
|
||||||
|
|
||||||
{% block title %}Hello SpeciesController!{% endblock %}
|
|
||||||
|
|
||||||
{% block body %}
|
|
||||||
<style>
|
|
||||||
.example-wrapper { margin: 1em auto; max-width: 800px; width: 95%; font: 18px/1.5 sans-serif; }
|
|
||||||
.example-wrapper code { background: #F5F5F5; padding: 2px 6px; }
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<div class="example-wrapper">
|
|
||||||
<h1>Hello {{ controller_name }}! ✅</h1>
|
|
||||||
|
|
||||||
This friendly message is coming from:
|
|
||||||
<ul>
|
|
||||||
<li>Your controller at <code>C:/wamp64/www/Symfony/herbarium/src/Controller/SpeciesController.php</code></li>
|
|
||||||
<li>Your template at <code>C:/wamp64/www/Symfony/herbarium/templates/species/index.html.twig</code></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
Loading…
Reference in new issue