mirror of
https://github.com/openseadragon/openseadragon.git
synced 2025-02-16 23:03:13 +03:00
change regex determining tilesUrl to accept file as iipserver parameter without slash in front
This commit is contained in:
parent
29f973029f
commit
ed93a32912
@ -140,7 +140,7 @@ $.extend( $.DziTileSource.prototype, $.TileSource.prototype, /** @lends OpenSead
|
|||||||
|
|
||||||
if (url && !options.tilesUrl) {
|
if (url && !options.tilesUrl) {
|
||||||
options.tilesUrl = url.replace(
|
options.tilesUrl = url.replace(
|
||||||
/([^\/]+?)(\.(dzi|xml|js))?(\?[^\/]*)?\/?$/, '$1_files/');
|
/([^\/]+?)(\.(dzi|xml|js)?(\?[^\/]*)?)?\/?$/, '$1_files/');
|
||||||
|
|
||||||
if (url.search(/\.(dzi|xml|js)\?/) != -1) {
|
if (url.search(/\.(dzi|xml|js)\?/) != -1) {
|
||||||
options.queryParams = url.match(/\?.*/);
|
options.queryParams = url.match(/\?.*/);
|
||||||
|
@ -36,6 +36,9 @@
|
|||||||
testImplicitTilesUrl(
|
testImplicitTilesUrl(
|
||||||
'/iiipsrv?DeepZoom=/path/my.dzi', '/iiipsrv?DeepZoom=/path/my_files/',
|
'/iiipsrv?DeepZoom=/path/my.dzi', '/iiipsrv?DeepZoom=/path/my_files/',
|
||||||
'querystring in dzi url should not be ignored before slashes');
|
'querystring in dzi url should not be ignored before slashes');
|
||||||
|
testImplicitTilesUrl(
|
||||||
|
'/fcg-bin/iipsrv.fcgi?Deepzoom=123test.tif.dzi', '/fcg-bin/iipsrv.fcgi?Deepzoom=123test.tif_files/',
|
||||||
|
'filename in querystring does not have to contain slash');
|
||||||
});
|
});
|
||||||
|
|
||||||
}());
|
}());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user