Commit 20a0e95fa7bde4d82d0b106a7327dda7c46a4e72

Authored by kevin_fourie
1 parent c65ff32f

KTS-2091

"Rename folder does not handle non-alphanumeric/accented characters correctly"
Fixed.

KTS-2076
"Character encoding issue with document titles"
Fixed.

Committed By: Kevin
Reviewed By: Conrad

git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/STABLE/trunk@6767 c91229c3-7414-0410-bfa2-8a42b809f60b
plugins/ktcore/folder/Rename.php
@@ -87,7 +87,7 @@ class KTFolderRenameAction extends KTFolderAction { @@ -87,7 +87,7 @@ class KTFolderRenameAction extends KTFolderAction {
87 } 87 }
88 } 88 }
89 89
90 - $res = KTFolderUtil::rename($this->oFolder, sanitize($sFolderName), $this->oUser); 90 + $res = KTFolderUtil::rename($this->oFolder, sanitizeForSQL($sFolderName), $this->oUser);
91 if (PEAR::isError($res)) { 91 if (PEAR::isError($res)) {
92 $_SESSION['KTErrorMessage'][] = $res->getMessage(); 92 $_SESSION['KTErrorMessage'][] = $res->getMessage();
93 redirect(KTBrowseUtil::getUrlForFolder($this->oFolder)); 93 redirect(KTBrowseUtil::getUrlForFolder($this->oFolder));
plugins/ktcore/folder/addDocument.php
@@ -276,7 +276,7 @@ class KTFolderAddDocumentAction extends KTFolderAction { @@ -276,7 +276,7 @@ class KTFolderAddDocumentAction extends KTFolderAction {
276 ); 276 );
277 277
278 $aFile = $this->oValidator->validateFile($extra_d['file'], $aErrorOptions); 278 $aFile = $this->oValidator->validateFile($extra_d['file'], $aErrorOptions);
279 - $sTitle = sanitize($extra_d['document_name']); 279 + $sTitle = sanitizeForSQL($extra_d['document_name']);
280 280
281 $iFolderId = $this->oFolder->getId(); 281 $iFolderId = $this->oFolder->getId();
282 $aOptions = array( 282 $aOptions = array(