Symfony\Bundle\FrameworkBundle\Controller\Controller::createNotFoundException
Returns a NotFoundHttpException.
This will result in a 404 response code. Usage example: throw $this->createNotFoundException('Page not found!');
Signature
public function createNotFoundException([string
$message = 'Not Found',
[Exception
$previous = null]] )
Parameters
$message
— string- A message
$previous
— \Exception- The previous exception
Returns
- NotFoundHttpException