mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-28 16:16:08 +03:00
Merge pull request #1074 from altert/smallfix
See #832, further fix for dzitilesource guessing of tilesUrl, for iii…
This commit is contained in:
commit
6a3b2d52c5
@ -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(/\?.*/);
|
||||||
|
@ -32,7 +32,10 @@
|
|||||||
'relative link should stay the same');
|
'relative link should stay the same');
|
||||||
testImplicitTilesUrl(
|
testImplicitTilesUrl(
|
||||||
'/p/foo.dzi?a=1&b=2', '/p/foo_files/',
|
'/p/foo.dzi?a=1&b=2', '/p/foo_files/',
|
||||||
'querystring in dzi url should be ignored');
|
'querystring in dzi url should be ignored after slashes');
|
||||||
|
testImplicitTilesUrl(
|
||||||
|
'/iiipsrv?DeepZoom=/path/my.dzi', '/iiipsrv?DeepZoom=/path/my_files/',
|
||||||
|
'querystring in dzi url should not be ignored before slashes');
|
||||||
});
|
});
|
||||||
|
|
||||||
}());
|
}());
|
||||||
|
Loading…
Reference in New Issue
Block a user