summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorBjörn Schießle <schiessle@owncloud.com>2012-11-07 10:45:29 +0100
committerBjörn Schießle <schiessle@owncloud.com>2012-11-07 10:47:19 +0100
commit12983cf0b0bd2829d9b2af30871580d83f5798ce (patch)
tree29a876e12b18d258e72ca32d6ea26f4567250020 /apps
parent3e01fe1dbb9e8f1830b7071f4368f23be04a4578 (diff)
downloadnextcloud-server-12983cf0b0bd2829d9b2af30871580d83f5798ce.tar.gz
nextcloud-server-12983cf0b0bd2829d9b2af30871580d83f5798ce.zip
urlencode file/dir to allow special characters in filename/path (issue #95)
Diffstat (limited to 'apps')
-rw-r--r--apps/files_sharing/public.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_sharing/public.php b/apps/files_sharing/public.php
index 295273d842b..598172aa855 100644
--- a/apps/files_sharing/public.php
+++ b/apps/files_sharing/public.php
@@ -70,9 +70,9 @@ if (isset($_GET['file']) || isset($_GET['dir'])) {
if (isset($linkItem['share_with'])) {
// Check password
if (isset($_GET['file'])) {
- $url = OCP\Util::linkToPublic('files').'&file='.$_GET['file'];
+ $url = OCP\Util::linkToPublic('files').'&file='.urlencode($_GET['file']);
} else {
- $url = OCP\Util::linkToPublic('files').'&dir='.$_GET['dir'];
+ $url = OCP\Util::linkToPublic('files').'&dir='.urlencode($_GET['dir']);
}
if (isset($_POST['password'])) {
$password = $_POST['password'];