mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-12 08:55:54 +00:00
trim name in setName()
This commit is contained in:
parent
88e0dcc58d
commit
7a5123aa6c
|
@ -53,7 +53,11 @@ class SeedDMS_Core_DocumentCategory {
|
|||
|
||||
function getName() { return $this->_name; }
|
||||
|
||||
function setName($newName) { /* {{{ */
|
||||
function setName($newName) { /* {{{ */
|
||||
$newName = trim($newName);
|
||||
if(!$name)
|
||||
return false;
|
||||
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
$queryStr = "UPDATE `tblCategory` SET `name` = ".$db->qstr($newName)." WHERE `id` = ". $this->_id;
|
||||
|
|
Loading…
Reference in New Issue
Block a user