<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Welcome extends CI_Controller {
public function __construct()
{
parent::__construct();
$this->load->library("common_lib");
$this->load->model("productm");
$this->load->model("commonm");
}
/**
* Index Page for this controller.
*
* Maps to the following URL
* http://example.com/index.php/welcome
* - or -
* http://example.com/index.php/welcome/index
* - or -
* Since this controller is set as the default controller in
* config/routes.php, it's displayed at http://example.com/
*
* So any other public methods not prefixed with an underscore will
* map to /index.php/welcome/<method_name>
* @see http://codeigniter.com/user_guide/general/urls.html
*/
public function index()
{
$data = array();
$data['show_slider'] = 1;
$data['product_list'] = $this->productm->get_latest_products("","new");
$data['featured_list'] = $this->productm->get_latest_products("","featured");
$data['hot_list'] = $this->productm->get_latest_products("","hot");
$data['popular_list'] = $this->productm->get_latest_products("","popular");
$data['top_banners'] = $this->commonm->get_all("homepage_settings");
$data['inner_template'] = "welcome_message";
$this->load->view('layout/layout_main.php',$data);
}
}
/* End of file welcome.php */
/* Location: ./application/controllers/welcome.php */
@KyuuKazami