Skip to content
Snippets Groups Projects
Commit 3a5076d6 authored by Björn Schießle's avatar Björn Schießle
Browse files

show pictures in folder with special characters, e.g. '+'

parent 4bc7387d
No related branches found
No related tags found
No related merge requests found
...@@ -22,7 +22,7 @@ function viewImage(dir, file) { ...@@ -22,7 +22,7 @@ function viewImage(dir, file) {
if(file.indexOf('.psd')>0){//can't view those if(file.indexOf('.psd')>0){//can't view those
return; return;
} }
var location=OC.filePath('files','ajax','download.php')+'?files='+file+'&dir='+dir; var location=OC.filePath('files','ajax','download.php')+'?files='+encodeURIComponent(file)+'&dir='+encodeURIComponent(dir);
$.fancybox({ $.fancybox({
"href": location, "href": location,
"title": file.replace(/</, "&lt;").replace(/>/, "&gt;"), "title": file.replace(/</, "&lt;").replace(/>/, "&gt;"),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment