You are here

public function TawktoGenerator::getIframeUrl in tawk.to Live Chat (Drupal 8) 8

Constructs url for configuration iframe.

1 call to TawktoGenerator::getIframeUrl()
TawktoGenerator::getIframe in tawk_to/src/core/TawktoGenerator.php

File

tawk_to/src/core/TawktoGenerator.php, line 80

Class

TawktoGenerator

Namespace

Drupal\tawk_to\core

Code

public function getIframeUrl() {
  if (!($widget = $this
    ->getWidgetVars())) {
    $widget = array(
      'page_id' => '',
      'widget_id' => '',
    );
  }
  return $this
    ->getBaseUrl() . '/generic/widgets?currentWidgetId=' . $widget['widget_id'] . '&currentPageId=' . $widget['page_id'];
}