Josh
  • Introduction
  • Philosophy
  • Contribution
  • Videos
  • Laravel 5.7
  • Laravel 5.6
  • Laravel 5.5
  • Laravel 5.4
  • Laravel 5.2, 5.3
    • Installating JOSH
    • Fresh Installation
  • Laravel 5.1
    • Installation
      • Database setup
      • Permissions
      • Mail Setup
      • Copying Josh Files
      • Install Josh
    • Customize whoops,...
    • usage
      • change skin
  • Laravel 5 Version
    • Installation
      • Database & Environment setup
      • Permissions
      • Mail Setup
      • Copying Josh files
      • Install Josh
    • FAQ
  • Laravel 4 Version
    • Features & Requirements
    • Installation
      • Database
      • Permissions
      • Mail
      • Copying Josh files
      • Install Josh
  • Laravel resources
    • Packages
    • Learning Laravel
    • Hosting
  • GUI CRUD
  • GULP
  • HTML Version
    • Layout
      • Header
      • Left Menu
      • Container
      • Footer Scripts
    • New Page
    • Boxed Version
    • UI Elements
    • Plugins Used
    • Images Used
    • Fonts Used
  • Updates
  • 3.0
    • 3.0.1
    • 3.1
    • 3.1.1
    • 3.1.2
    • 3.2
    • 3.2.1
    • 3.2.2
    • 3.2.3
    • 3.2.4
    • 3.2.5
    • 3.2.5.1
    • 3.2.6
  • 4.0
    • 4.0.1
    • 4.1
    • 4.2
    • 4.3
    • 4.3.1
    • 4.3.2
  • 5.0
  • Social Login
  • Recaptcha
Powered by GitBook
On this page

Was this helpful?

  1. Laravel 5.1

Customize whoops,...

If you would like to replace that message with 500.blade.php file shipped with Josh, please follow below tutorial.

to do so, we should override convertExceptionToResponse method in app/Exceptions/Handler.php

add below code into your app/Exceptions/Handler.php

    /**
     * Convert the given exception into a Response instance.
     *
     * @param \Exception $e
     *
     * @return \Symfony\Component\HttpFoundation\Response
     */
    protected function convertExceptionToResponse(Exception $e)
    {
        $debug = config('app.debug', false);

        if ($debug) {
            return (new SymfonyDisplayer($debug))->createResponse($e);
        }

        return response()->view('admin.500');
    }
PreviousInstall JoshNextusage

Last updated 5 years ago

Was this helpful?

credits