]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix download url generation
authorBart Visscher <bartv@thisnet.nl>
Sat, 27 Oct 2012 13:10:21 +0000 (15:10 +0200)
committerBart Visscher <bartv@thisnet.nl>
Sat, 27 Oct 2012 13:10:21 +0000 (15:10 +0200)
apps/files/js/fileactions.js
core/js/js.js

index 0cf4a05222585c4e69fc40bf5e35257e97e927e0..1cf80352bef2e4fdbcaaf7b4aaf1358bcfdede6a 100644 (file)
@@ -157,7 +157,7 @@ $(document).ready(function(){
                var downloadScope = 'file';
        }
        FileActions.register(downloadScope,'Download', OC.PERMISSION_READ, function(){return OC.imagePath('core','actions/download');},function(filename){
-               window.location=OC.filePath('files', 'ajax', 'download.php') + '&files='+encodeURIComponent(filename)+'&dir='+encodeURIComponent($('#dir').val());
+               window.location=OC.filePath('files', 'ajax', 'download.php') + '?files='+encodeURIComponent(filename)+'&dir='+encodeURIComponent($('#dir').val());
        });
 });
 
index 130d413296ebbfb9d9b254b613e4295081404692..6ed50b42bd5097ba47295c357451c9c9330825ea 100644 (file)
@@ -62,7 +62,7 @@ function escapeHTML(s) {
 * @return string
 */
 function fileDownloadPath(dir, file) {
-       return OC.filePath('files', 'ajax', 'download.php')+'&files='+encodeURIComponent(file)+'&dir='+encodeURIComponent(dir);
+       return OC.filePath('files', 'ajax', 'download.php')+'?files='+encodeURIComponent(file)+'&dir='+encodeURIComponent(dir);
 }
 
 var OC={