You are here

function PMPAPIDrupal::sdkInclude in Public Media Platform API Integration 7

Includes a file from the SDK

Parameters

string $file: The file name - minus the file extension

3 calls to PMPAPIDrupal::sdkInclude()
PMPAPIDrupal::getDoc in classes/PMPAPIDrupal.php
Gets a doc from the PMP.
PMPAPIDrupal::pull in classes/PMPAPIDrupal.php
Pulls from the PMP.
PMPAPIDrupal::__construct in classes/PMPAPIDrupal.php
Initializes a PMPAPIDrupal object.

File

classes/PMPAPIDrupal.php, line 375
Defines a class for PMP creation/transmission and retreival/parsing

Class

PMPAPIDrupal
@file

Code

function sdkInclude($file) {
  $dir_path = 'phpsdk/lib/Pmp/Sdk/';
  if (module_load_include('php', 'pmpapi', $dir_path . $file)) {
    return TRUE;
  }
  else {
    require_once DRUPAL_ROOT . '/sites/all/libraries/' . $dir_path . $file . '.php';
  }
}