CakePHP
  • Documentation
    • Book
    • API
    • Videos
    • Reporting Security Issues
    • Privacy Policy
    • Logos & Trademarks
  • Business Solutions
  • Swag
  • Road Trip
  • Team
  • Community
    • Community
    • Get Involved
    • Issues (Github)
    • Bakery
    • Featured Resources
    • Training
    • Meetups
    • My CakePHP
    • CakeFest
    • Newsletter
    • Linkedin
    • YouTube
    • Facebook
    • Twitter
    • Mastodon
    • Help & Support
    • Forum
    • Stack Overflow
    • IRC
    • Slack
    • Paid Support
CakePHP

C CakePHP 4.6 Strawberry API

  • Project:
    • CakePHP
      • CakePHP
      • Authentication
      • Authorization
      • Chronos
      • Elastic Search
      • Queue
  • Version:
    • 4.6
      • 5.2
      • 5.1
      • 5.0
      • 4.6
      • 4.5
      • 4.4
      • 4.3
      • 4.2
      • 4.1
      • 4.0
      • 3.10
      • 3.9
      • 3.8
      • 3.7
      • 3.6
      • 3.5
      • 3.4
      • 3.3
      • 3.2
      • 3.1
      • 3.0
      • 2.10
      • 2.9
      • 2.8
      • 2.7
      • 2.6
      • 2.5
      • 2.4
      • 2.3
      • 2.2
      • 2.1
      • 2.0
      • 1.3
      • 1.2

Namespaces

  • Global
  • Cake
    • Auth
    • Cache
    • Collection
    • Command
    • Console
    • Controller
    • Core
    • Database
    • Datasource
    • Error
    • Event
    • Filesystem
    • Form
    • Http
    • I18n
    • Log
    • Mailer
    • Network
    • ORM
    • Routing
    • Shell
    • TestSuite
    • Utility
    • Validation
    • View

Namespace Error

Namespaces

  • Cake\Error\Debug
  • Cake\Error\Middleware
  • Cake\Error\Renderer

Function Detail

dd() ¶

dd(mixed $var, bool|null $showHtml = null): void

Prints out debug information about given variable and dies.

Only runs if debug mode is enabled. It will otherwise just continue code execution and ignore this function.

Parameters
mixed $var

Variable to show debug information for.

bool|null $showHtml optional

If set to true, the method prints the debug data in a browser-friendly way.

Returns
void
Links
https://book.cakephp.org/4/en/development/debugging.html#basic-debugging

debug() ¶

debug(mixed $var, bool|null $showHtml = null, bool $showFrom = true): mixed

Prints out debug information about given variable and returns the variable that was passed.

Only runs if debug mode is enabled.

Parameters
mixed $var

Variable to show debug information for.

bool|null $showHtml optional

If set to true, the method prints the debug data in a browser-friendly way.

bool $showFrom optional

If set to true, the method prints from where the function was called.

Returns
mixed
Links
https://book.cakephp.org/4/en/development/debugging.html#basic-debugging

https://book.cakephp.org/4/en/core-libraries/global-constants-and-functions.html#debug

stackTrace() ¶

stackTrace(array<string, mixed> $options = []): void

Outputs a stack trace based on the supplied options.

Options

  • depth - The number of stack frames to return. Defaults to 999
  • args - Should arguments for functions be shown? If true, the arguments for each method call will be displayed.
  • start - The stack frame to start generating a trace from. Defaults to 1
Parameters
array<string, mixed> $options optional

Format for outputting stack trace

Returns
void

Interfaces

  • ErrorLoggerInterface

    Interface for error logging handlers.

  • ErrorRendererInterface

    Interface for PHP error rendering implementations

  • ExceptionRendererInterface

    Interface ExceptionRendererInterface

Classes

  • BaseErrorHandler

    Base error handler that provides logic common to the CLI + web error/exception handlers.

  • ConsoleErrorHandler

    Error Handler for Cake console. Does simple printing of the exception that occurred and the stack trace of the error.

  • Debugger

    Provide custom logging and error handling.

  • ErrorHandler

    Error Handler provides basic error and exception handling for your application. It captures and handles all unhandled exceptions and errors. Displays helpful framework errors when debug mode is on.

  • ErrorLogger

    Log errors and unhandled exceptions to Cake\Log\Log

  • ErrorTrap

    Entry point to CakePHP's error handling.

  • ExceptionRenderer

    Backwards compatible Exception Renderer.

  • ExceptionTrap

    Entry point to CakePHP's exception handling.

  • FatalErrorException

    Represents a fatal error

  • PhpError

    Object wrapper around PHP errors that are emitted by trigger_error()

OpenHub
Pingping
Linode
  • Business Solutions
  • Showcase
  • Documentation
  • Book
  • API
  • Videos
  • Reporting Security Issues
  • Privacy Policy
  • Logos & Trademarks
  • Community
  • Get Involved
  • Issues (Github)
  • Bakery
  • Featured Resources
  • Training
  • Meetups
  • My CakePHP
  • CakeFest
  • Newsletter
  • Linkedin
  • YouTube
  • Facebook
  • Twitter
  • Mastodon
  • Help & Support
  • Forum
  • Stack Overflow
  • IRC
  • Slack
  • Paid Support

Generated using CakePHP API Docs