From e5c96c160f627be28a159222b40a2a62485170ce Mon Sep 17 00:00:00 2001 From: Sebastian Meyer Date: Fri, 22 Dec 2017 10:45:11 +0100 Subject: [PATCH] Get metadataPrefix even when resuming lists --- oai2server.php | 2 +- oai2transform.xsl | 29 ++++++++++++++++++++++------- 2 files changed, 23 insertions(+), 8 deletions(-) diff --git a/oai2server.php b/oai2server.php index 0f92dc6..b899986 100644 --- a/oai2server.php +++ b/oai2server.php @@ -245,7 +245,7 @@ class OAI2Server { private function createResumptionToken($deliveredRecords, $metadataPrefix, $from, $until) { list($usec, $sec) = explode(' ', microtime()); $token = ((int)($usec*1000) + (int)($sec*1000)); - $file = fopen($this->token_prefix.$token, 'w'); + $file = fopen($this->token_prefix.$token.'#'.$metadataPrefix, 'w'); if($file == false) { exit('Cannot write resumption token. Writing permission needs to be changed.'); } diff --git a/oai2transform.xsl b/oai2transform.xsl index a68b2aa..e0533ad 100644 --- a/oai2transform.xsl +++ b/oai2transform.xsl @@ -137,8 +137,13 @@ - + + + + + + @@ -296,7 +301,12 @@ Metadata Format Details ListIdentifiers --> -

This is a list of records' identifiers available for the metadata format .

+ +

This is a list of records' identifiers available for the metadata format .

+
+ +

This is a resumed list of records' identifiers available for the requested metadata format.

+
@@ -308,7 +318,7 @@ ListIdentifiers

Record Header

@@ -330,7 +340,12 @@ ListIdentifiers ListRecords --> -

This is a list of records available for the metadata format .

+ +

This is a list of records available for the metadata format .

+
+ +

This is a resumed list of records available for the requested metadata format.

+
@@ -361,7 +376,7 @@ Record Details

Record

Identifier
@@ -400,7 +415,7 @@ Resumption Token Unknown Metadata --> -

Metadata Format

+

Metadata ()

@@ -410,7 +425,7 @@ Unknown Metadata DublinCore Metadata --> -

Metadata Format DublinCore

+

Metadata (DublinCore)

Identifier