You are here

class WebformShareHelper in Webform 6.x

Same name and namespace in other branches
  1. 8.5 modules/webform_share/src/WebformShareHelper.php \Drupal\webform_share\WebformShareHelper

Webform share helper class.

Hierarchy

Expanded class hierarchy of WebformShareHelper

3 files declare their use of WebformShareHelper
WebformShareEventSubscriber.php in modules/webform_share/src/EventSubscriber/WebformShareEventSubscriber.php
WebformShareThemeNegotiator.php in modules/webform_share/src/Theme/WebformShareThemeNegotiator.php
webform_share.module in modules/webform_share/webform_share.module
Allows webforms to be shared on other websites using an iframe.

File

modules/webform_share/src/WebformShareHelper.php, line 10

Namespace

Drupal\webform_share
View source
class WebformShareHelper {

  /**
   * Determine if the current page is a webform share page.
   *
   * @return bool
   *   TRUE if the current page is a webform share page.
   */
  public static function isPage(RouteMatchInterface $route_match = NULL) {
    $route_match = $route_match ?: \Drupal::routeMatch();
    return strpos($route_match
      ->getRouteName(), 'entity.webform.share_page') === 0;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
WebformShareHelper::isPage public static function Determine if the current page is a webform share page.