2017 © Pedro Peláez
 

cakephp-plugin cakephp-apache-error-theme

Make error pages Apache web server style.

image

tenkoma/cakephp-apache-error-theme

Make error pages Apache web server style.

  • Tuesday, April 11, 2017
  • by tenkoma
  • Repository
  • 1 Watchers
  • 0 Stars
  • 3 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

CakePHP Apache error theme plugin

Make error pages Apache web server style., (*1)

Not Found, (*2)

Installation

You can install using composer., (*3)

composer require tenkoma/cakephp-apache-error-theme

Enable Plugin

You can load the plugin using the shell command:, (*4)

bin/cake plugin load CakeApacheErrorTheme

Or you can manually add the loading statement in the config/bootstrap.php file of your application:, (*5)

// config/bootstrap.php
Plugin::load('CakeApacheErrorTheme');

Enable theme

set theme in the ErrorController::beforeRender()., (*6)

// src/Controller/ErrorController.php
    public function beforeRender(Event $event)
    {
        parent::beforeRender($event);

        $this->viewBuilder()->theme('CakeApacheErrorTheme');
    }

and debug = false in the config/app.php, (*7)

// config/app.php
    'debug' => false,

Configure

// config/bootstrap.php
Configure::write('CakeApacheErrorTheme', [
    'signature' => 'cake',
    'email' => 'webmaster@example.com',
]);
  • signature
    • apache (default)
    • cake show CakePHP and version as signature.
  • email (default=webmaster@localhost) E-mail address to be displayed at 5xx error

Example

404 Not Found

Not Found, (*8)

5xx Internal Error

Internal Error, (*9)

The Versions

11/04 2017

dev-master

9999999-dev

Make error pages Apache web server style.

  Sources   Download

MIT

The Requires

 

by Koji Tanaka

21/01 2017

0.1

0.1.0.0

Make error pages Apache web server style.

  Sources   Download

MIT

The Requires

 

by Koji Tanaka