| Server IP : 45.40.142.9 / Your IP : 216.73.216.250 Web Server : Apache System : Linux s45-40-142-9.secureserver.net 2.6.32-754.35.1.el6.x86_64 #1 SMP Sat Nov 7 12:42:14 UTC 2020 x86_64 User : bayspec ( 506) PHP Version : 5.6.40 Disable Function : NONE MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/bayspec/public_html/system/modification/catalog/controller/module/ |
Upload File : |
<?php
class ControllerModuleParallax extends Controller {
public function index($setting) {
static $module = 0;
$this->load->model('design/banner');
$this->load->model('tool/image');
$this->document->addScript('catalog/view/javascript/parallax/cherry-fixed-parallax.js');
$this->document->addStyle('catalog/view/javascript/parallax/css/parallax.css');
$data['banners'] = array();
$results = $this->model_design_banner->getBanner($setting['banner_id']);
foreach ($results as $result) {
if (is_file(DIR_IMAGE . $result['image'])) {
$data['banners'][] = array(
'description' => html_entity_decode($result['description']),
'title' => $result['title'],
'link' => $result['link'],
'image' => $this->model_tool_image->resize($result['image'], $setting['width'], $setting['height'])
);
}
}
$data['module'] = $module++;
if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/module/parallax.tpl')) {
return $this->load->view($this->config->get('config_template') . '/template/module/parallax.tpl', $data);
} else {
return $this->load->view('default/template/module/parallax.tpl', $data);
}
}
}