function en8_startElement in Bibliography Module 5
Same name and namespace in other branches
- 6 endnote8_parser.inc \en8_startElement()
1 string reference to 'en8_startElement'
File
- ./
endnote8_parser.inc, line 3
Code
function en8_startElement($parser, $name, $attrs) {
global $node_array, $node, $node_id, $element, $contributors, $titles, $periodical, $dates, $urls;
switch ($name) {
case 'record':
$node_id = array_push($node_array, $node) - 1;
break;
case 'style':
break;
case 'author':
switch ($contributors) {
case 'authors':
$node_array[$node_id]['biblio_authors'] .= empty($node_array[$node_id]['biblio_authors']) ? "" : "; ";
break;
case 'secondary-authors':
$node_array[$node_id]['biblio_secondary_authors'] .= empty($node_array[$node_id]['biblio_secondary_authors']) ? "" : "; ";
break;
case 'tertiary-authors':
$node_array[$node_id]['biblio_tertiary_authors'] .= empty($node_array[$node_id]['biblio_tertiary_authors']) ? "" : "; ";
break;
case 'subsidiary-authors':
$node_array[$node_id]['biblio_subsidiary_authors'] .= empty($node_array[$node_id]['biblio_subsidiary_authors']) ? "" : "; ";
break;
case 'translated-authors':
$node_array[$node_id]['biblio_translated_authors'] .= empty($node_array[$node_id]['biblio_translated_authors']) ? "" : "; ";
break;
}
$element = $name;
break;
case 'authors':
case 'secondary-authors':
case 'tertiary-authors':
case 'subsidiary-authors':
case 'translated-authors':
$contributors = $name;
break;
case 'year':
case 'pub-dates':
case 'copyright-dates':
$dates = $name;
break;
case 'web-urls':
case 'pdf-urls':
case 'text-urls':
case 'related-urls':
case 'image-urls':
$urls = $name;
break;
default:
$element = $name;
}
}