You are here

public static function InstapageCmsPluginConnector::isDrupal8 in Instapage plugin 8.3

Same name and namespace in other branches
  1. 7.3 core/connectors/InstapageCmsPluginConnector.php \InstapageCmsPluginConnector::isDrupal8()

Checks if Drupal 8 is a currently used CMS.

Return value

boolean

1 call to InstapageCmsPluginConnector::isDrupal8()
InstapageCmsPluginConnector::getSelectedConnector in core/connectors/InstapageCmsPluginConnector.php
Selects a proper connector based on currently used CMS.

File

core/connectors/InstapageCmsPluginConnector.php, line 60

Class

InstapageCmsPluginConnector
Main connector class, used to integrate with PHP-based CMSes. It's job is to detect a CMS that executes the code and select proper CMS Connector.

Code

public static function isDrupal8() {
  if (class_exists('\\Drupal\\Core\\DrupalKernel')) {
    return true;
  }
  return false;
}