Back to CoreButtonsTrait class

Method help

public \Joomla\CMS\Toolbar\Button\HelpButton
help
(mixed $ref, mixed $useComponent = false, mixed $url = null, mixed $component = null)
Writes a help button for a given option (opens a popup window).
Parameters
  • string $ref The name of the popup file (excluding the file extension for an xml file).
  • bool $useComponent Use the help file in the component directory.
  • string $url Use this URL instead of any other.
  • string $component Name of component to get Help (null for current component)
Returns
  • \Joomla\CMS\Toolbar\Button\HelpButton
Since
  • 4.0.0

Method help - Source code

/**
 * Writes a help button for a given option (opens a popup window).
 *
 * @param   string  $ref           The name of the popup file (excluding the file extension for an xml file).
 * @param   bool    $useComponent  Use the help file in the component directory.
 * @param   string  $url           Use this URL instead of any other.
 * @param   string  $component     Name of component to get Help (null for current component)
 *
 * @return  HelpButton
 *
 * @since   4.0.0
 */
public function help($ref, $useComponent = false, $url = null, $component = null) : HelpButton
{
    return $this->helpButton('help', 'JTOOLBAR_HELP')->ref($ref)->useComponent($useComponent)->url($url)->component($component);
}