aboutsummaryrefslogtreecommitdiff
path: root/h-source/Application/Controllers/GenericController.php
diff options
context:
space:
mode:
Diffstat (limited to 'h-source/Application/Controllers/GenericController.php')
-rw-r--r--h-source/Application/Controllers/GenericController.php12
1 files changed, 12 insertions, 0 deletions
diff --git a/h-source/Application/Controllers/GenericController.php b/h-source/Application/Controllers/GenericController.php
index 0c140b3..656060d 100644
--- a/h-source/Application/Controllers/GenericController.php
+++ b/h-source/Application/Controllers/GenericController.php
@@ -850,6 +850,18 @@ class GenericController extends BaseController
}
}
+ //if preview
+ if (isset($_POST['previewAction']))
+ {
+ if ($this->s['registered']->status['status'] === 'logged')
+ {
+ if (!$this->s['registered']->checkCsrf($clean['token'])) $this->redirect($this->controller.'/catalogue/'.$this->lang,2,'wrong token..');
+
+ $data['preview_message'] = $this->request->post('message','','sanitizeHtml');
+ $this->m['TalkModel']->result = false;
+ }
+ }
+
$data['table'] = $this->m['TalkModel']->select()->where(array('id_hard'=>$clean['id_hard']))->orderBy('id_talk')->send();
$data['values'] = $this->m['TalkModel']->getFormValues('insert','sanitizeHtml');