public function TawkToWidgetController::widgetsContent in Tawk.to - Live chat application (Drupal 8) 8
Same name and namespace in other branches
- 8.2 src/Controller/TawkToWidgetController.php \Drupal\tawk_to\Controller\TawkToWidgetController::widgetsContent()
Constructs a widgets content.
Return value
array Renderable array.
1 string reference to 'TawkToWidgetController::widgetsContent'
File
- src/
Controller/ TawkToWidgetController.php, line 89
Class
- TawkToWidgetController
- Controller routine that manages tawk.to widget settings.
Namespace
Drupal\tawk_to\ControllerCode
public function widgetsContent() {
$items = [];
$items['baseUrl'] = self::TAWK_TO_PLUGINS_URL;
$items['iframeUrl'] = $this
->tawkToGetIframeUrl();
return [
'#theme' => 'tawk_to_iframe',
'#items' => $items,
];
}