Kaynağa Gözat

Added logic to match unlabelled abstract fields

main
Simon Bowie 4 yıl önce
ebeveyn
işleme
69027eda64
1 değiştirilmiş dosya ile 7 ekleme ve 2 silme
  1. +7
    -2
      site/solr.php

+ 7
- 2
site/solr.php Dosyayı Görüntüle

$output['title'] = $title[1]; $output['title'] = $title[1];


// Search for the abstract in the content element and display it // Search for the abstract in the content element and display it
preg_match('/Abstract.*\n(.*)\n/', $content, $abstract);
$output['abstract'] = $abstract[1];
if (preg_match('/Abstract.*\n(.*)\n/', $content, $abstract)){
$output['abstract'] = $abstract[1];
}
else {
preg_match('/\(.\) \\n\\n(.*)\\n/', $content, $abstract);
$output['abstract'] = $abstract[1];
}


return $output; return $output;



Yükleniyor…
İptal
Kaydet