xssbook2/web/_controller/template.php
2024-03-30 12:14:42 -04:00

22 lines
541 B
PHP

<?php /* Copyright (c) 2024 Freya Murphy */
class Template_controller extends Controller {
// the request model
private $request_model;
function __construct($load) {
parent::__construct($load);
$this->request_model = $this->load->model('request');
}
public function toast(): void {
$data = array(
'msg' => $this->request_model->get_str('msg', FALSE),
'detail' => $this->request_model->get_str('detail', FALSE),
'hint' => $this->request_model->get_str('hint', FALSE)
);
$this->view('template/toast', $data);
}
}