aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files
diff options
context:
space:
mode:
authorJan-Christoph Borchardt <hey@jancborchardt.net>2012-10-30 14:23:38 +0100
committerJan-Christoph Borchardt <hey@jancborchardt.net>2012-10-30 14:23:38 +0100
commit3db43a9980049c80d9f3cd2cf510b8a527189ded (patch)
tree2d0b8c6af00ea9944ab50953654a034984203288 /apps/files
parentdb5e8f3eeac46708d4a437fded5d83fb6eaad558 (diff)
parent3fdf239b478273155a68ec4ede8d4e4dd54b504d (diff)
downloadnextcloud-server-3db43a9980049c80d9f3cd2cf510b8a527189ded.tar.gz
nextcloud-server-3db43a9980049c80d9f3cd2cf510b8a527189ded.zip
Merge branch 'master' into navigation
Diffstat (limited to 'apps/files')
-rw-r--r--apps/files/ajax/move.php7
-rw-r--r--apps/files/ajax/timezone.php5
-rw-r--r--apps/files/appinfo/remote.php4
-rw-r--r--apps/files/index.php2
-rw-r--r--apps/files/js/fileactions.js6
-rw-r--r--apps/files/l10n/de.php2
-rw-r--r--apps/files/l10n/de_DE.php26
-rw-r--r--apps/files/l10n/th_TH.php14
8 files changed, 41 insertions, 25 deletions
diff --git a/apps/files/ajax/move.php b/apps/files/ajax/move.php
index ddcda553e3d..0541bb16062 100644
--- a/apps/files/ajax/move.php
+++ b/apps/files/ajax/move.php
@@ -9,9 +9,14 @@ OCP\JSON::callCheck();
// Get data
$dir = stripslashes($_GET["dir"]);
$file = stripslashes($_GET["file"]);
-$target = stripslashes(urldecode($_GET["target"]));
+$target = stripslashes(rawurldecode($_GET["target"]));
+if(OC_Filesystem::file_exists($target . '/' . $file)){
+ OCP\JSON::error(array("data" => array( "message" => "Could not move $file - File with this name already exists" )));
+ exit;
+}
+
if(OC_Files::move($dir, $file, $target, $file)) {
OCP\JSON::success(array("data" => array( "dir" => $dir, "files" => $file )));
} else {
diff --git a/apps/files/ajax/timezone.php b/apps/files/ajax/timezone.php
index b71fa3940cb..b547d162b3e 100644
--- a/apps/files/ajax/timezone.php
+++ b/apps/files/ajax/timezone.php
@@ -1,5 +1,2 @@
<?php
- // FIXME: this should start a secure session if forcessl is enabled
- // see lib/base.php for an example
- //session_start();
- $_SESSION['timezone'] = $_GET['time'];
+$_SESSION['timezone'] = $_GET['time'];
diff --git a/apps/files/appinfo/remote.php b/apps/files/appinfo/remote.php
index a84216b61b7..9c7b9ab6d5b 100644
--- a/apps/files/appinfo/remote.php
+++ b/apps/files/appinfo/remote.php
@@ -23,7 +23,7 @@
*
*/
// only need filesystem apps
-$RUNTIME_APPTYPES=array('filesystem','authentication');
+$RUNTIME_APPTYPES=array('filesystem', 'authentication');
OC_App::loadApps($RUNTIME_APPTYPES);
// Backends
@@ -38,7 +38,7 @@ $server = new Sabre_DAV_Server($publicDir);
$server->setBaseUri($baseuri);
// Load plugins
-$server->addPlugin(new Sabre_DAV_Auth_Plugin($authBackend,'ownCloud'));
+$server->addPlugin(new Sabre_DAV_Auth_Plugin($authBackend, 'ownCloud'));
$server->addPlugin(new Sabre_DAV_Locks_Plugin($lockBackend));
$server->addPlugin(new Sabre_DAV_Browser_Plugin(false)); // Show something in the Browser, but no upload
diff --git a/apps/files/index.php b/apps/files/index.php
index 3441e371a31..8b8b0fd7610 100644
--- a/apps/files/index.php
+++ b/apps/files/index.php
@@ -36,7 +36,7 @@ if(!isset($_SESSION['timezone'])) {
}
OCP\App::setActiveNavigationEntry( 'files_index' );
// Load the files
-$dir = isset( $_GET['dir'] ) ? urldecode(stripslashes($_GET['dir'])) : '';
+$dir = isset( $_GET['dir'] ) ? rawurldecode(stripslashes($_GET['dir'])) : '';
// Redirect if directory does not exist
if(!OC_Filesystem::is_dir($dir.'/')) {
header('Location: '.$_SERVER['SCRIPT_NAME'].'');
diff --git a/apps/files/js/fileactions.js b/apps/files/js/fileactions.js
index 24c8e85656c..82d990bf780 100644
--- a/apps/files/js/fileactions.js
+++ b/apps/files/js/fileactions.js
@@ -80,9 +80,9 @@ var FileActions = {
if (img.call) {
img = img(file);
}
- var html = '<a href="#" class="action">';
+ var html = '<a href="#" class="action" data-action="'+name+'">';
if (img) {
- html += '<img src="' + img + '"/> ';
+ html += '<img class ="svg" src="' + img + '"/> ';
}
html += t('files', name) + '</a>';
var element = $(html);
@@ -111,7 +111,7 @@ var FileActions = {
}
var element = $(html);
if (img) {
- element.append($('<img src="' + img + '"/>'));
+ element.append($('<img class ="svg" src="' + img + '"/>'));
}
element.data('action', 'Delete');
element.click(function (event) {
diff --git a/apps/files/l10n/de.php b/apps/files/l10n/de.php
index 545f840d8ce..7dc5831e639 100644
--- a/apps/files/l10n/de.php
+++ b/apps/files/l10n/de.php
@@ -37,7 +37,7 @@
"{count} folders" => "{count} Ordner",
"1 file" => "1 Datei",
"{count} files" => "{count} Dateien",
-"seconds ago" => "Vor wenigen Sekunden",
+"seconds ago" => "Gerade eben",
"1 minute ago" => "vor einer Minute",
"{minutes} minutes ago" => "Vor {minutes} Minuten",
"today" => "Heute",
diff --git a/apps/files/l10n/de_DE.php b/apps/files/l10n/de_DE.php
index 37e77472ab6..194bf6b4fda 100644
--- a/apps/files/l10n/de_DE.php
+++ b/apps/files/l10n/de_DE.php
@@ -1,10 +1,10 @@
<?php $TRANSLATIONS = array(
-"There is no error, the file uploaded with success" => "Datei fehlerfrei hochgeladen.",
+"There is no error, the file uploaded with success" => "Es sind keine Fehler aufgetreten. Die Datei wurde erfolgreich hochgeladen.",
"The uploaded file exceeds the upload_max_filesize directive in php.ini" => "Die Größe der hochzuladenden Datei überschreitet die upload_max_filesize-Richtlinie in php.ini",
"The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form" => "Die Größe der hochzuladenden Datei überschreitet die MAX_FILE_SIZE-Richtlinie, die im HTML-Formular angegeben wurde",
"The uploaded file was only partially uploaded" => "Die Datei wurde nur teilweise hochgeladen.",
"No file was uploaded" => "Es wurde keine Datei hochgeladen.",
-"Missing a temporary folder" => "Temporärer Ordner fehlt.",
+"Missing a temporary folder" => "Der temporäre Ordner fehlt.",
"Failed to write to disk" => "Fehler beim Schreiben auf die Festplatte",
"Files" => "Dateien",
"Unshare" => "Nicht mehr freigeben",
@@ -14,19 +14,19 @@
"replace" => "ersetzen",
"suggest name" => "Name vorschlagen",
"cancel" => "abbrechen",
-"replaced {new_name}" => "{new_name} ersetzt",
+"replaced {new_name}" => "{new_name} wurde ersetzt",
"undo" => "rückgängig machen",
-"replaced {new_name} with {old_name}" => "{old_name} ersetzt durch {new_name}",
+"replaced {new_name} with {old_name}" => "{old_name} wurde ersetzt durch {new_name}",
"unshared {files}" => "Freigabe für {files} beendet",
"deleted {files}" => "{files} gelöscht",
"generating ZIP-file, it may take some time." => "Erstelle ZIP-Datei. Dies kann eine Weile dauern.",
"Unable to upload your file as it is a directory or has 0 bytes" => "Ihre Datei kann nicht hochgeladen werden, da sie entweder ein Verzeichnis oder 0 Bytes groß ist.",
"Upload Error" => "Fehler beim Upload",
"Pending" => "Ausstehend",
-"1 file uploading" => "Eine Datei wird hoch geladen",
+"1 file uploading" => "1 Datei wird hochgeladen",
"{count} files uploading" => "{count} Dateien wurden hochgeladen",
"Upload cancelled." => "Upload abgebrochen.",
-"File upload is in progress. Leaving the page now will cancel the upload." => "Dateiupload läuft. Wenn Sie die Seite jetzt verlassen, wird der Upload abgebrochen.",
+"File upload is in progress. Leaving the page now will cancel the upload." => "Der Dateiupload läuft. Wenn Sie die Seite jetzt verlassen, wird der Upload abgebrochen.",
"Invalid name, '/' is not allowed." => "Ungültiger Name: \"/\" ist nicht erlaubt.",
"{count} files scanned" => "{count} Dateien wurden gescannt",
"error while scanning" => "Fehler beim Scannen",
@@ -37,16 +37,16 @@
"{count} folders" => "{count} Ordner",
"1 file" => "1 Datei",
"{count} files" => "{count} Dateien",
-"seconds ago" => "Vor wenigen Sekunden",
-"1 minute ago" => "vor einer Minute",
-"{minutes} minutes ago" => "vor {minutes} Minuten",
+"seconds ago" => "Gerade eben",
+"1 minute ago" => "Vor 1 Minute",
+"{minutes} minutes ago" => "Vor {minutes} Minuten",
"today" => "Heute",
"yesterday" => "Gestern",
-"{days} days ago" => "vor {days} Tage(en)",
+"{days} days ago" => "Vor {days} Tage(en)",
"last month" => "Letzten Monat",
-"months ago" => "Monate her",
+"months ago" => "Vor Monaten",
"last year" => "Letztes Jahr",
-"years ago" => "Jahre her",
+"years ago" => "Vor Jahren",
"File handling" => "Dateibehandlung",
"Maximum upload size" => "Maximale Upload-Größe",
"max. possible: " => "maximal möglich:",
@@ -64,7 +64,7 @@
"Nothing in here. Upload something!" => "Alles leer. Bitte laden Sie etwas hoch!",
"Share" => "Teilen",
"Download" => "Herunterladen",
-"Upload too large" => "Upload zu groß",
+"Upload too large" => "Der Upload ist zu groß",
"The files you are trying to upload exceed the maximum size for file uploads on this server." => "Die Datei überschreitet die Maximalgröße für Uploads auf diesem Server.",
"Files are being scanned, please wait." => "Dateien werden gescannt, bitte warten.",
"Current scanning" => "Scanne"
diff --git a/apps/files/l10n/th_TH.php b/apps/files/l10n/th_TH.php
index 3645435e54b..9bde85229b4 100644
--- a/apps/files/l10n/th_TH.php
+++ b/apps/files/l10n/th_TH.php
@@ -10,25 +10,39 @@
"Unshare" => "ยกเลิกการแชร์ข้อมูล",
"Delete" => "ลบ",
"Rename" => "เปลี่ยนชื่อ",
+"{new_name} already exists" => "{new_name} มีอยู่แล้วในระบบ",
"replace" => "แทนที่",
"suggest name" => "แนะนำชื่อ",
"cancel" => "ยกเลิก",
+"replaced {new_name}" => "แทนที่ {new_name} แล้ว",
"undo" => "เลิกทำ",
+"replaced {new_name} with {old_name}" => "แทนที่ {new_name} ด้วย {old_name} แล้ว",
+"unshared {files}" => "ยกเลิกการแชร์แล้ว {files} ไฟล์",
+"deleted {files}" => "ลบไฟล์แล้ว {files} ไฟล์",
"generating ZIP-file, it may take some time." => "กำลังสร้างไฟล์บีบอัด ZIP อาจใช้เวลาสักครู่",
"Unable to upload your file as it is a directory or has 0 bytes" => "ไม่สามารถอัพโหลดไฟล์ของคุณได้ เนื่องจากไฟล์ดังกล่าวเป็นไดเร็กทอรี่หรือมีขนาด 0 ไบต์",
"Upload Error" => "เกิดข้อผิดพลาดในการอัพโหลด",
"Pending" => "อยู่ระหว่างดำเนินการ",
"1 file uploading" => "กำลังอัพโหลดไฟล์ 1 ไฟล์",
+"{count} files uploading" => "กำลังอัพโหลด {count} ไฟล์",
"Upload cancelled." => "การอัพโหลดถูกยกเลิก",
"File upload is in progress. Leaving the page now will cancel the upload." => "การอัพโหลดไฟล์กำลังอยู่ในระหว่างดำเนินการ การออกจากหน้าเว็บนี้จะทำให้การอัพโหลดถูกยกเลิก",
"Invalid name, '/' is not allowed." => "ชื่อที่ใช้ไม่ถูกต้อง '/' ไม่อนุญาตให้ใช้งาน",
+"{count} files scanned" => "สแกนไฟล์แล้ว {count} ไฟล์",
"error while scanning" => "พบข้อผิดพลาดในระหว่างการสแกนไฟล์",
"Name" => "ชื่อ",
"Size" => "ขนาด",
"Modified" => "ปรับปรุงล่าสุด",
+"1 folder" => "1 โฟลเดอร์",
+"{count} folders" => "{count} โฟลเดอร์",
+"1 file" => "1 ไฟล์",
+"{count} files" => "{count} ไฟล์",
"seconds ago" => "วินาที ก่อนหน้านี้",
+"1 minute ago" => "1 นาทีก่อนหน้านี้",
+"{minutes} minutes ago" => "{minutes} นาทีก่อนหน้านี้",
"today" => "วันนี้",
"yesterday" => "เมื่อวานนี้",
+"{days} days ago" => "{day} วันก่อนหน้านี้",
"last month" => "เดือนที่แล้ว",
"months ago" => "เดือน ที่ผ่านมา",
"last year" => "ปีที่แล้ว",