<?php
if (!defined('_PS_VERSION_'))
exit;
class TmMediaParallax extends Module{
public function install(){
if (Shop::isFeatureActive())
Shop::setContext(Shop::CONTEXT_ALL);
if(!parent::install() ||
!$this->installDB() ||
!$this->registerHook('displayNav') ||
!$this->registerHook('displayHeader') ||
!$this->registerHook('displayFooter') ||
!$this->registerHook('displayHome') ||
!$this->registerHook('displayTopColumn') ||
!$this->registerHook('displayTop') ||
!Configuration::updateValue('smooth_scroll_on', 1) ||
!Configuration::updateValue('smooth_scroll_time', '330') ||
!Configuration::updateValue('smooth_scroll_distance', '100')
)
return false;
return true;
}
public function uninstall(){
if (!Db::getInstance()->Execute('DROP TABLE IF EXISTS `'._DB_PREFIX_.'tmmediaparallax`') || !parent::uninstall())
return false;
return true;
}