private function BiblioEntrezPubmedArticle::abst in Bibliography Module 6
Same name and namespace in other branches
- 6.2 modules/pubmed/EntrezPubmedArticle.php \BiblioEntrezPubmedArticle::abst()
- 7 modules/pubmed/EntrezPubmedArticle.php \BiblioEntrezPubmedArticle::abst()
- 7.2 modules/pubmed/EntrezPubmedArticle.php \BiblioEntrezPubmedArticle::abst()
1 call to BiblioEntrezPubmedArticle::abst()
- BiblioEntrezPubmedArticle::getBiblio in pubmed/EntrezPubmedArticle.php 
- Returns article elements as an associative array suitable for import into a biblio node.
File
- pubmed/EntrezPubmedArticle.php, line 184 
- EntrezPubmedArticle.php Provides a class for handling PubMed articles retrieved with EFetch. Orginally writen by Stefan Freudenberg
Class
- BiblioEntrezPubmedArticle
- @file EntrezPubmedArticle.php Provides a class for handling PubMed articles retrieved with EFetch. Orginally writen by Stefan Freudenberg
Code
private function abst() {
  if (isset($this->article->Article->Abstract)) {
    $abst = '';
    foreach ($this->article->Article->Abstract->AbstractText as $text) {
      if (!empty($abst)) {
        $abst .= "\n\n";
      }
      $attrs = $text
        ->attributes();
      if (isset($attrs['Label'])) {
        $abst .= $attrs['Label'] . ': ';
      }
      $abst .= (string) $text;
    }
    return $abst;
  }
}