I am working on jobeet tutorial. When I am running the project on localhost like this:
http://localhost/Symfony/web/app_dev.php/ens_job/
I am getting a error
A template that extends another one cannot have a body in EnslJobeetBundle:Job:index.html.twig at line 7.
What should I do in this case?
I am using the index.html.twig as follow:
<!-- src/Ens/JobeetBundle/Resources/views/Job/index.html.twig --> {% extends 'EnsJobeetBundle::layout.html.twig' %} {% block stylesheets %} {{ parent() }} <link rel="stylesheet" href="{{ asset('bundles/ensjobeet/css/jobs.css') }}" type="text/css" media="all" /> {% endblock %} <!-- the rest of the code -->
This error occurs when you have content out of blocks
in child template.
You have to remove <!-- src/Ensl/JobeetBundle/Resources/views/Job/index.html.twig -->
from your index.html.twig
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With