<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class MY_Controller extends CI_Controller 
 { 
   var $template  = array();
   var $data      = array();
   
   public function layout() {
     $this->template['header']   = $this->load->view('layout/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->template['footer'] = $this->load->view('layout/footer', $this->data, true);
     $this->load->view('layout/index', $this->template);
   }
   
   public function adminlayout() {
     $this->template['header']   = $this->load->view('admin/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->load->view('admin/index', $this->template);
   }
   
   public function storelayout() {
     $this->template['header']   = $this->load->view('store/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->load->view('store/index', $this->template);
   } 
   
   public function trlayout() {
     $this->template['header']   = $this->load->view('transporter/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->load->view('transporter/index', $this->template);
   } 
   
   public function slayout() {
     $this->template['header']   = $this->load->view('seller/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->load->view('seller/index', $this->template);
   }
   
   public function citylayout() {
     $this->template['header']   = $this->load->view('cityadmin/header', $this->data, true);
     $this->template['middle'] = $this->load->view($this->middle, $this->data, true);
     $this->load->view('cityadmin/index', $this->template);
   }
}
?>