Symfony Exception

NotFoundHttpException

HTTP 404 Not Found

Przepraszamy podana strona nie istnieje

Exception

Symfony\Component\HttpKernel\Exception\ NotFoundHttpException

  1.      *
  2.      * @return NotFoundHttpException
  3.      */
  4.     protected function createNotFoundException($message 'Not Found', \Exception $previous null)
  5.     {
  6.         return new NotFoundHttpException($message$previous);
  7.     }
  8.     /**
  9.      * Returns an AccessDeniedException.
  10.      *
Controller->createNotFoundException('Przepraszamy podana strona nie istnieje') in src/MGraphics/Site/FrontendBundle/Controller/ProductController.php (line 22)
  1.     public function productAction($product){
  2.         
  3.         $em $this->getDoctrine()->getManager();
  4.         $entity $em->getRepository("MGraphicsSiteCoreBundle:Product")->findOneBySlug($product);
  5.         if(!$entity){
  6.             throw $this->createNotFoundException('Przepraszamy podana strona nie istnieje');
  7.         }
  8.         return $this->render(
  9.                 'frontend/product/product.html.twig',
  10.                 array('product' => $entity)
  11.             );
ProductController->productAction('audi-q5-premium-2016-38')
call_user_func_array(array(object(ProductController), 'productAction'), array('audi-q5-premium-2016-38')) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php (line 153)
  1.         $this->dispatcher->dispatch(KernelEvents::CONTROLLER_ARGUMENTS$event);
  2.         $controller $event->getController();
  3.         $arguments $event->getArguments();
  4.         // call controller
  5.         $response call_user_func_array($controller$arguments);
  6.         // view
  7.         if (!$response instanceof Response) {
  8.             $event = new GetResponseForControllerResultEvent($this$request$type$response);
  9.             $this->dispatcher->dispatch(KernelEvents::VIEW$event);
HttpKernel->handleRaw(object(Request), 1) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php (line 68)
  1.     public function handle(Request $request$type HttpKernelInterface::MASTER_REQUEST$catch true)
  2.     {
  3.         $request->headers->set('X-Php-Ob-Level'ob_get_level());
  4.         try {
  5.             return $this->handleRaw($request$type);
  6.         } catch (\Exception $e) {
  7.             if ($e instanceof RequestExceptionInterface) {
  8.                 $e = new BadRequestHttpException($e->getMessage(), $e);
  9.             }
  10.             if (false === $catch) {
HttpKernel->handle(object(Request), 1, true) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php (line 169)
  1.     {
  2.         if (false === $this->booted) {
  3.             $this->boot();
  4.         }
  5.         return $this->getHttpKernel()->handle($request$type$catch);
  6.     }
  7.     /**
  8.      * Gets a HTTP kernel from the container.
  9.      *
Kernel->handle(object(Request), 1, true) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php (line 465)
  1.             $trustedProxies[] = '127.0.0.1';
  2.             Request::setTrustedProxies($trustedProxiesRequest::HEADER_X_FORWARDED_ALL);
  3.         }
  4.         // always a "master" request (as the real master request can be in cache)
  5.         $response $this->kernel->handle($requestHttpKernelInterface::MASTER_REQUEST$catch);
  6.         // FIXME: we probably need to also catch exceptions if raw === true
  7.         // we don't implement the stale-if-error on Requests, which is nonetheless part of the RFC
  8.         if (null !== $entry && in_array($response->getStatusCode(), array(500502503504))) {
  9.             if (null === $age $entry->headers->getCacheControlDirective('stale-if-error')) {
HttpCache->forward(object(Request), true, null) in vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/HttpCache/HttpCache.php (line 57)
  1.     protected function forward(Request $request$raw falseResponse $entry null)
  2.     {
  3.         $this->getKernel()->boot();
  4.         $this->getKernel()->getContainer()->set('cache'$this);
  5.         return parent::forward($request$raw$entry);
  6.     }
  7.     /**
  8.      * Returns an array of options to customize the Cache configuration.
  9.      *
HttpCache->forward(object(Request), true) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php (line 419)
  1.         // avoid that the backend sends no content
  2.         $subRequest->headers->remove('if_modified_since');
  3.         $subRequest->headers->remove('if_none_match');
  4.         $response $this->forward($subRequest$catch);
  5.         if ($response->isCacheable()) {
  6.             $this->store($request$response);
  7.         }
HttpCache->fetch(object(Request), true) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php (line 316)
  1.         }
  2.         if (null === $entry) {
  3.             $this->record($request'miss');
  4.             return $this->fetch($request$catch);
  5.         }
  6.         if (!$this->isFreshEnough($request$entry)) {
  7.             $this->record($request'stale');
HttpCache->lookup(object(Request), true) in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php (line 191)
  1.                 reload the cache by fetching a fresh response and caching it (if possible).
  2.             */
  3.             $this->record($request'reload');
  4.             $response $this->fetch($request$catch);
  5.         } else {
  6.             $response $this->lookup($request$catch);
  7.         }
  8.         $this->restoreResponseBody($request$response);
  9.         if (HttpKernelInterface::MASTER_REQUEST === $type && $this->options['debug']) {
HttpCache->handle(object(Request)) in public_html/app.php (line 15)
  1. $kernel->loadClassCache();
  2. $kernel = new AppCache($kernel);
  3. Request::enableHttpMethodParameterOverride();
  4. $request Request::createFromGlobals();
  5. $response $kernel->handle($request);
  6. $response->send();
  7. $kernel->terminate($request$response);

Logs

No log messages

Stack Trace

NotFoundHttpException

Symfony\Component\HttpKernel\Exception\NotFoundHttpException:
Przepraszamy podana strona nie istnieje

  at vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Controller/ControllerTrait.php:300
  at Symfony\Bundle\FrameworkBundle\Controller\Controller->createNotFoundException('Przepraszamy podana strona nie istnieje')
     (src/MGraphics/Site/FrontendBundle/Controller/ProductController.php:22)
  at MGraphics\Site\FrontendBundle\Controller\ProductController->productAction('audi-q5-premium-2016-38')
  at call_user_func_array(array(object(ProductController), 'productAction'), array('audi-q5-premium-2016-38'))
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php:153)
  at Symfony\Component\HttpKernel\HttpKernel->handleRaw(object(Request), 1)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php:68)
  at Symfony\Component\HttpKernel\HttpKernel->handle(object(Request), 1, true)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php:169)
  at Symfony\Component\HttpKernel\Kernel->handle(object(Request), 1, true)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php:465)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->forward(object(Request), true, null)
     (vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/HttpCache/HttpCache.php:57)
  at Symfony\Bundle\FrameworkBundle\HttpCache\HttpCache->forward(object(Request), true)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php:419)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->fetch(object(Request), true)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php:316)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->lookup(object(Request), true)
     (vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpCache/HttpCache.php:191)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->handle(object(Request))
     (public_html/app.php:15)