Fixes problems with thumbnails for filenames with single and double quotes.
This commit is contained in:
parent
42d3dfe80e
commit
d56d0716cb
2 changed files with 4 additions and 3 deletions
|
@ -37,7 +37,7 @@ h5ai is provided under the terms of the [MIT License](http://github.com/lrsjng/h
|
||||||
* fixes include problems in PHP version
|
* fixes include problems in PHP version
|
||||||
* fixes path problems on servers running on Windows in PHP version
|
* fixes path problems on servers running on Windows in PHP version
|
||||||
* fixes broken links in custom headers/footers while zipped download enabled
|
* fixes broken links in custom headers/footers while zipped download enabled
|
||||||
|
* fixes problems with thumbnails for files with single or double quotes in filename
|
||||||
|
|
||||||
### v0.17 - *2011-11-28*
|
### v0.17 - *2011-11-28*
|
||||||
|
|
||||||
|
|
|
@ -74,8 +74,9 @@
|
||||||
|
|
||||||
if (H5AI.core.settings.showThumbs === true && $.inArray(path.type, thumbTypes) >= 0) {
|
if (H5AI.core.settings.showThumbs === true && $.inArray(path.type, thumbTypes) >= 0) {
|
||||||
imgClass = "class='thumb'";
|
imgClass = "class='thumb'";
|
||||||
icon16 = H5AI.core.api() + "?action=thumb&href=" + path.absHref + "&width=16&height=16&mode=square";
|
var escapedHref = path.absHref.replace(/'/g, "%27").replace(/"/g, "%22");
|
||||||
icon48 = H5AI.core.api() + "?action=thumb&href=" + path.absHref + "&width=96&height=46&mode=rational";
|
icon16 = H5AI.core.api() + "?action=thumb&href=" + escapedHref + "&width=16&height=16&mode=square";
|
||||||
|
icon48 = H5AI.core.api() + "?action=thumb&href=" + escapedHref + "&width=96&height=46&mode=rational";
|
||||||
}
|
}
|
||||||
|
|
||||||
$label = $("<span class='label'>" + path.label + "</span>");
|
$label = $("<span class='label'>" + path.label + "</span>");
|
||||||
|
|
Loading…
Add table
Reference in a new issue