ส่วนของไฟล์ controller // check.php
โค้ด: เลือกทั้งหมด
<?php
namespace mindphp\m_check_pass\controller;
class main
{
public function __construct(\phpbb\config\config $config, \phpbb\template\template $template, \phpbb\user $user, \phpbb\controller\helper $helper, $root_path, $php_ext)
{
$this->config = $config;
$this->template = $template;
$this->user = $user;
$this->helper = $helper;
$this->root_path = $root_path;
$this->php_ext = $php_ext;
}
public function base($page = 1)
{
return $this->helper->render('checkpass_body.html');
}
}
?>
ส่วนของ Config // routing.yml
โค้ด: เลือกทั้งหมด
m_check_pass_controller:
pattern: /m_check_pass
defaults: { _controller: mindphp.m_check_pass.controller:base, page: 1 }
ส่วนของ Template
โค้ด: เลือกทั้งหมด
<!-- INCLUDE overall_header.html -->
Test Sample1 By Mindphp.com
<!-- INCLUDE overall_footer.html -->
ผลที่ต้องการคือให้แสดงข้อความในเทมเพลต