27 lines
622 B
PHP
27 lines
622 B
PHP
<?php
|
|
|
|
namespace KupShop\ContentBundle\Controller;
|
|
|
|
use KupShop\ContentBundle\View\RobotstxtView;
|
|
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
|
use Symfony\Component\HttpFoundation\Response;
|
|
use Symfony\Component\Routing\Annotation\Route;
|
|
|
|
class RobotstxtController extends AbstractController
|
|
{
|
|
/**
|
|
* @var Response
|
|
*
|
|
* @return Response
|
|
*
|
|
* @Route("/robots.txt")
|
|
*/
|
|
public function robotstxtAction(RobotstxtView $view)
|
|
{
|
|
$response = $view->getResponse();
|
|
$response->headers->set('Content-Type', 'text/plain');
|
|
|
|
return $response;
|
|
}
|
|
}
|