You are here

function physical_volume_unit_name in Physical Fields 7

Returns the name of a volume unit of measurement.

Parameters

string $type: The type of volume unit whose name should be returned; by default this can be l, m3, ml, fl oz, pt, gal.

Return value

string|bool The name of the specified unit of measurement or FALSE if not found.

File

./physical.module, line 624
Defines fields (e.g. weight and dimensions) to support describing the physical attributes of entities.

Code

function physical_volume_unit_name($type) {
  $units = physical_volume_units();
  if (!empty($units[$type]['name'])) {
    return $units[$type]['name'];
  }
  return FALSE;
}