Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision |
buechereielektrik:unapi:unapi.php [2010-01-10 22:24] – Some style improvements, added comments, removed some old code. rosenke | buechereielektrik:unapi:unapi.php [2010-02-19 13:18] – Added csv as format. strols |
---|
* <ftp://ftp.ub.uni-marburg.de/pub/research/unapi.tar.gz>. | * <ftp://ftp.ub.uni-marburg.de/pub/research/unapi.tar.gz>. |
* | * |
* Copyright 2009 2010 Stephan Rosenke <rosenke@ulb.tu-darmstadt.de>. | * Copyright 2009 2010 Stephan Rosenke <rosenke@ulb.tu-darmstadt.de> or |
| * <r01-551@r0s.de>. See also <http://r0s.de/unapi>. |
*/ | */ |
| |
* Version | * Version |
* | * |
* 0.1 | * 0.5 |
*/ | */ |
| |
* Changelog | * Changelog |
* | * |
| * 20100219: Added csv as format. |
| * 20100127: Added link in copyright. |
| * 20100111: Added openurl-kev as format. |
* 20100110: Some style improvements, added comments, removed some old code. | * 20100110: Some style improvements, added comments, removed some old code. |
* 20100109: Some style improvements, added comments. | * 20100109: Some style improvements, added comments. |
<formats> | <formats> |
<format name=\"bibtex\" type=\"text/plain\" /> | <format name=\"bibtex\" type=\"text/plain\" /> |
| <format name=\"csv\" type=\"text/plain\" /> |
<format name=\"dc\" type=\"application/xml\" /> | <format name=\"dc\" type=\"application/xml\" /> |
<format name=\"extpp\" type=\"application/xml\" /> | <format name=\"extpp\" type=\"application/xml\" /> |
<format name=\"json\" type=\"application/json\" /> | <format name=\"json\" type=\"application/json\" /> |
| <format name=\"openurl-kev\" type=\"text/plain\" /> |
<format name=\"rdf\" type=\"application/xml\" /> | <format name=\"rdf\" type=\"application/xml\" /> |
<format name=\"text\" type=\"text/plain\" /> | <format name=\"text\" type=\"text/plain\" /> |
case 'bibtex': | case 'bibtex': |
$res = $pica->getBibTex(); | $res = $pica->getBibTex(); |
| final_result($res, 'text/plain'); |
| break; |
| // CSV |
| case 'csv': |
| $res = $pica->getCsv(); |
final_result($res, 'text/plain'); | final_result($res, 'text/plain'); |
break; | break; |
$res = $pica->getJson(); | $res = $pica->getJson(); |
final_result($res, 'application/json'); | final_result($res, 'application/json'); |
| break; |
| // OpenURL-KEV |
| case 'openurl-kev': |
| $res = $pica->getOpenUrlKev(); |
| final_result($res, 'text/plain'); |
break; | break; |
// pseudo-XML | // pseudo-XML |