Skip to main content
Skip table of contents

Callable Functions

PHPv8+ allows for dynamically generated callable functions. This syntax allows you to modularize your Custom Logic.'

Example:

This example defines and stores a new function into the $fnctName variable. This function-variable can then be invoked later using the call notation.

PHP
$fnctName = function(
  $parameter1,
  $parameter2,
  // ... more params if needed
){
  // Do something in the function
  // with the parameters
};

$fnctName->call($this, $param1, $param2);

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.