added some trim's around name, template and lang so that whitespace gets not saved

This commit is contained in:
Ralf Becker 2003-03-27 23:42:28 +00:00
parent a5a5d245d8
commit 3d394c5b50

View File

@ -165,7 +165,7 @@
{ {
case 'vbox': case 'vbox':
case 'hbox': case 'hbox':
case 'stack': case 'deck':
$cell['cell_tpl'] = '.vbox'; $cell['cell_tpl'] = '.vbox';
break; break;
} }
@ -243,7 +243,7 @@
{ {
case 'vbox': case 'vbox':
case 'hbox': case 'hbox':
case 'stack': case 'deck':
if ($cell['size'] < 2) if ($cell['size'] < 2)
{ {
$cell['size'] = 2; $cell['size'] = 2;
@ -443,7 +443,7 @@
{ {
$this->etemplate->modified = time(); $this->etemplate->modified = time();
} }
$ok = $this->etemplate->save($content['name'],$content['template'],$content['lang'],$content['group'],$content['version']); $ok = $this->etemplate->save(trim($content['name']),trim($content['template']),trim($content['lang']),intval($content['group']),trim($content['version']));
$msg = $this->messages[$ok ? 'saved' : 'error_writing']; $msg = $this->messages[$ok ? 'saved' : 'error_writing'];
} }
elseif ($content['show']) elseif ($content['show'])