You are here

function Record::subfield in Bibliography Module 7.2

Same name and namespace in other branches
  1. 6.2 modules/marcParse/php-marc.php \Record::subfield()
  2. 6 marcParse/php-marc.php \Record::subfield()
  3. 7 modules/marcParse/php-marc.php \Record::subfield()

Get subfield of Field object

Returns the value of a specific subfield of a given Field object

Parameters

string Name of field:

string Name of subfield:

Return value

string|FALSE Return value of subfield if Field exists, otherwise FALSE

File

modules/marcParse/php-marc.php, line 557

Class

Record
Record Class Create a MARC Record class

Code

function subfield($field, $subfield) {
  if (!($field = $this
    ->field($field))) {
    return FALSE;
  }
  else {
    return $field
      ->subfield($subfield);
  }
}