<?php
class ControllerextensionModulekefu extends Controller {
	public function index($setting) {
		$data['titlt'] = $setting['title'];
        $data['miconbj'] = $setting['miconbj'];		
        $data['miconcolorc'] = $setting['miconcolorc'];
		$data['miconcolor'] = $setting['miconcolor'];
        $data['hoverbj'] = $setting['hoverbj'];
        $data['hovertit'] = $setting['hovertit'];	
		$data['miconround'] = $setting['miconround'];
		$data['miconsize'] = $setting['miconsize'];
		$data['miconborder'] = $setting['miconborder'];
		$data['miconbc'] = $setting['miconbc'];
		$data['miconwidth'] = $setting['miconwidth'];
		$data['miconheight'] = $setting['miconheight'];	
		static $module = 0;

		$this->load->model('tool/image');

		if (is_file(DIR_IMAGE . $setting['image'])) {
			$image = $setting['image'];
		} else {
			$image = 'placeholder.png';
		}

		$data['image'] = $this->model_tool_image->resize($image, $setting['width'], $setting['height']);

		$data['title'] = $setting['title'];
		$data['sqqq'] = $setting['sqqq'];
		$data['shqq'] = $setting['shqq'];
		$data['shqq1'] = $setting['shqq1'];
		$data['shqq2'] = $setting['shqq2'];
		$data['sqalww'] = $setting['sqalww'];
		$data['alww'] = $setting['alww'];
		$data['telephone'] = $setting['telephone'];
		$data['telephone2'] = $setting['telephone2'];
		$data['time'] = $setting['time'];

		if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . 'extension/module/kefu.tpl')) {
			return $this->load->view($this->config->get('config_template') . 'extension/module/kefu.tpl', $data);
		} else {
			return $this->load->view('extension/module/kefu.tpl', $data);
		}
	}
}