mirror of
https://github.com/standardebooks/web.git
synced 2025-07-07 07:10:29 -04:00
Fix nationalmuseum.se URL normalization in artwork DB
This commit is contained in:
parent
1bc946f7b5
commit
3f091b0aa8
1 changed files with 2 additions and 2 deletions
|
@ -90,7 +90,7 @@ class Museum extends PropertiesBase{
|
||||||
return $outputUrl;
|
return $outputUrl;
|
||||||
}
|
}
|
||||||
elseif(preg_match('/\bnationalmuseum\.se$/ius', $parsedUrl['host'])){
|
elseif(preg_match('/\bnationalmuseum\.se$/ius', $parsedUrl['host'])){
|
||||||
$exampleUrl = 'https://collection.nationalmuseum.se/eMP/eMuseumPlus?objectId=18217';
|
$exampleUrl = 'https://collection.nationalmuseum.se/eMP/eMuseumPlus?service=ExternalInterface&module=collection&objectId=18217';
|
||||||
|
|
||||||
if($parsedUrl['host'] != 'collection.nationalmuseum.se'){
|
if($parsedUrl['host'] != 'collection.nationalmuseum.se'){
|
||||||
throw new Exceptions\InvalidMuseumUrlException($url, $exampleUrl);
|
throw new Exceptions\InvalidMuseumUrlException($url, $exampleUrl);
|
||||||
|
@ -110,7 +110,7 @@ class Museum extends PropertiesBase{
|
||||||
throw new Exceptions\InvalidPageScanUrlException($url, $exampleUrl);
|
throw new Exceptions\InvalidPageScanUrlException($url, $exampleUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
$outputUrl = 'https://' . $parsedUrl['host'] . $parsedUrl['path'] . '?objectId=' . $vars['objectId'];
|
$outputUrl = 'https://' . $parsedUrl['host'] . $parsedUrl['path'] . '?service=ExternalInterface&module=collection&objectId=' . $vars['objectId'];
|
||||||
|
|
||||||
return $outputUrl;
|
return $outputUrl;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue