public function OpenDialogCommand::__construct

Constructs an OpenDialogCommand object.

Parameters

string $selector: The selector of the dialog.

string $title: The title of the dialog.

string $html: HTML that will be placed in the dialog.

array $dialog_options: (optional) Options to be passed to the dialog implementation. Any jQuery UI option can be used. See http://api.jqueryui.com/dialog.

array|null $settings: (optional) Custom settings that will be passed to the Drupal behaviors on the content of the dialog. If left empty, the settings will be populated automatically from the current request.

1 call to OpenDialogCommand::__construct()
OpenModalDialogCommand::__construct in drupal/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php
Constructs an OpenModalDialog object.
1 method overrides OpenDialogCommand::__construct()
OpenModalDialogCommand::__construct in drupal/core/lib/Drupal/Core/Ajax/OpenModalDialogCommand.php
Constructs an OpenModalDialog object.

File

drupal/core/lib/Drupal/Core/Ajax/OpenDialogCommand.php, line 71
Contains \Drupal\Core\Ajax\OpenDialogCommand.

Class

OpenDialogCommand
Defines an AJAX command to open certain content in a dialog.

Namespace

Drupal\Core\Ajax

Code

public function __construct($selector, $title, $html, array $dialog_options = array(), $settings = NULL) {
  $dialog_options += array(
    'title' => $title,
  );
  $this->selector = $selector;
  $this->html = $html;
  $this->dialogOptions = $dialog_options;
  $this->settings = $settings;
}