Mon super article 2
Le super formidable contenu
تسجيل الدخول لنشر تعليق
Choose your language
٣ أكتوبر ٢٠٢٣ في ٩:٥٢:٠٤ ص Tom Doe
Le super formidable contenu
تسجيل الدخول لنشر تعليق
هذا هو تطبيق تجريبى تم بناءه بواسطه اطار سيمفوني لتوضيح الطريقة الموصى بها لتطوير تطبيقات سيمفوني.
لمزيد من المعلومات, راجع مستند سيمفوني.
اظغط على هذا الزر لعرض كود المتحكم و القالب المستخدم لعرض هذه الصفحه.
src/Controller/BlogController.php at line 76
/**
* NOTE: The $post controller argument is automatically injected by Symfony
* after performing a database query looking for a Post with the 'slug'
* value given in the route.
*
* See https://symfony.com/doc/current/bundles/SensioFrameworkExtraBundle/annotations/converters.html
*/
#[Route('/posts/{slug}', name: 'blog_post', methods: ['GET'])]
public function postShow(Post $post): Response
{
// Symfony's 'dump()' function is an improved version of PHP's 'var_dump()' but
// it's not available in the 'prod' environment to prevent leaking sensitive information.
// It can be used both in PHP files and Twig templates, but it requires to
// have enabled the DebugBundle. Uncomment the following line to see it in action:
//
// dump($post, $this->getUser(), new \DateTime());
//
// The result will be displayed either in the Symfony Profiler or in the stream output.
// See https://symfony.com/doc/current/profiler.html
// See https://symfony.com/doc/current/templates.html#the-dump-twig-utilities
//
// You can also leverage Symfony's 'dd()' function that dumps and
// stops the execution
return $this->render('blog/post_show.html.twig', ['post' => $post]);
}
كن اول من يعلق على هذا المنشور.