public function CloseModalDialogCommand::__construct

public CloseModalDialogCommand::__construct($persist = FALSE)

Constructs a CloseModalDialogCommand object.

Parameters

bool $persist: (optional) Whether to persist the dialog in the DOM or not.

Overrides CloseDialogCommand::__construct

File

core/lib/Drupal/Core/Ajax/CloseModalDialogCommand.php, line 18

Class

CloseModalDialogCommand
Defines an AJAX command that closes the currently visible modal dialog.

Namespace

Drupal\Core\Ajax

Code

public function __construct($persist = FALSE) {
  $this->selector = '#drupal-modal';
  $this->persist = $persist;
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Ajax!CloseModalDialogCommand.php/function/CloseModalDialogCommand::__construct/8.1.x