X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=export.php;h=7ccce33088e4196265119874a48a9ae2d26897d0;hb=074e8daef75c2b729e75f350b52935a6b7ecfba8;hp=3c46a5b5c2552db6c773f3b7352de489254d4409;hpb=d26c95718cac0a2994ab4e9633b59f420a0816b4;p=timetracker.git diff --git a/export.php b/export.php index 3c46a5b5..7ccce330 100644 --- a/export.php +++ b/export.php @@ -31,7 +31,7 @@ import('ttExportHelper'); import('form.Form'); // Access check. -if (!ttAccessCheck(right_export_team)) { +if (!ttAccessAllowed('export_data')) { header('Location: access_denied.php'); exit(); } @@ -45,7 +45,7 @@ $form = new Form('exportForm'); $form->addInput(array('type'=>'combobox','name'=>'compression','value'=>$cl_compression,'data'=>$compressors)); $form->addInput(array('type'=>'submit','name'=>'btn_submit','value'=>$i18n->getKey('button.export'))); -if ($request->getMethod() == 'POST') { +if ($request->isPost()) { $filename = 'team_data.xml'; $mime_type = 'text/xml'; @@ -74,8 +74,8 @@ if ($request->getMethod() == 'POST') { } exit; } else - $errors->add($i18n->getKey('error.sys')); -} + $err->add($i18n->getKey('error.sys')); +} // isPost $smarty->assign('forms', array($form->getName()=>$form->toArray())); $smarty->assign('title', $i18n->getKey('title.export'));