You are here

static function RealisticDummyContentEnvironment::getFileParts in Realistic Dummy Content 7

2 calls to RealisticDummyContentEnvironment::getFileParts()
RealisticDummyContentEnvironment::addFileToArray in api/includes/RealisticDummyContentEnvironment.inc
RealisticDummyContentEnvironment::validCandidateFilename in api/includes/RealisticDummyContentEnvironment.inc

File

api/includes/RealisticDummyContentEnvironment.inc, line 269
Define RealisticDummyContentLiveEnvironment autoload class.

Class

RealisticDummyContentEnvironment
The abstract base environment.

Code

static function getFileParts($name) {
  $return = array();
  $parts = explode('.', $name);
  if (count($parts) >= 4) {
    $return['attribute_extention'] = array_pop($parts);
    $return['attribute_name'] = array_pop($parts);
  }
  $return['base'] = implode('.', $parts);
  $return['base_extension'] = array_pop($parts);
  return $return;
}