Index: branches/5.2.x/core/kernel/db/cat_dbitem.php =================================================================== diff -u -N -r14092 -r14095 --- branches/5.2.x/core/kernel/db/cat_dbitem.php (.../cat_dbitem.php) (revision 14092) +++ branches/5.2.x/core/kernel/db/cat_dbitem.php (.../cat_dbitem.php) (revision 14095) @@ -1,6 +1,6 @@ usePendingEditing = $this->Application->getUnitOption($this->Prefix, 'UsePendingEditing'); } @@ -147,7 +148,7 @@ return $this->Create($cat_id); } - function NameCopy($master=null, $foreign_key=null) + public function NameCopy($master=null, $foreign_key=null, $title_field=null, $format='Copy %1$s of %2$s') { $title_field = $this->Application->getUnitOption($this->Prefix, 'TitleField'); if (!$title_field) return; @@ -300,7 +301,7 @@ function stripDisallowed($filename) { $filenames_helper =& $this->Application->recallObject('FilenamesHelper'); - $table = $this->mode == 't' ? $this->Application->GetTempName(TABLE_PREFIX.'CategoryItems', 'prefix:'.$this->Prefix) : TABLE_PREFIX.'CategoryItems'; + $table = $this->IsTempTable() ? $this->Application->GetTempName(TABLE_PREFIX.'CategoryItems', 'prefix:'.$this->Prefix) : TABLE_PREFIX.'CategoryItems'; return $filenames_helper->stripDisallowed($table, 'ItemResourceId', $this->GetDBField('ResourceId'), $filename); }