Drupal 7 从 "Salesforce suite" 初始化 salesforce REST API 服务
Drupal 7 initalising salesforce REST API service from "Salesforce suite"
由于我没有使用 Drupal 的经验,因此我 运行 遇到了一个小问题,试图从 salesforce REST API 调用 Web 服务。基于 Drupal 8 的示例,我有以下代码
$client = \Drupal::service('salesforce.client');
如果我在 Drupal 7 上尝试给出的示例,我会收到以下错误:
Class 'Drupal' not found in ..."
我想知道 Drupal 7 的替代品是什么。
The module "Service" is part of Drupal8 core. See
drupal.org/project/services for Drupal 7.
@Syscall 回答
由于我没有使用 Drupal 的经验,因此我 运行 遇到了一个小问题,试图从 salesforce REST API 调用 Web 服务。基于 Drupal 8 的示例,我有以下代码
$client = \Drupal::service('salesforce.client');
如果我在 Drupal 7 上尝试给出的示例,我会收到以下错误:
Class 'Drupal' not found in ..."
我想知道 Drupal 7 的替代品是什么。
The module "Service" is part of Drupal8 core. See drupal.org/project/services for Drupal 7.
@Syscall 回答