first commit

This commit is contained in:
pakerpale
2020-06-10 06:21:34 +09:00
commit 20c9739ba9
1913 changed files with 266257 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
<?php if (!defined('BASEPATH')) {
exit('No direct script access allowed');
}
class Cmtv extends MY_Controller
{
public function __construct()
{
echo '<script>history.back()</script>';
die('준비중입니다.');
parent::__construct();
$this->load->model('post_model', 'post');
}
public function index()
{
$totSegments = $this->uri->total_segments();
if (!is_numeric($this->uri->segment($totSegments))) {
$pageURL = $this->uri->segment($totSegments);
} elseif (is_numeric($this->uri->segment($totSegments))) {
$pageURL = $this->uri->segment($totSegments - 1);
}
if ($pageURL == "") {
$pageURL = "home";
}
$this->data['page'] = $this->page_model->getOne($pageURL);
$this->data['postGroup'] = [];
$recentUpdatedPosts = $this->db->where('categoryID', 30022)->get('cm_page_attributes')->result();
foreach ($recentUpdatedPosts as $p) {
array_push($this->data['postGroup'], $this->post->getPagePostsByPageId($p->pageID, 4));
}
$this->data['header'] = $this->load->view('templates/others/header', $this->data, true);
$this->data['footer'] = $this->load->view('templates/others/footer', '', true);
$this->load->view('templates/others/prayer', $this->data);
}
}