// Context in modules + Shop::sql* methods

This commit is contained in:
rMalie
2011-07-19 09:23:10 +00:00
parent 6551a3ece7
commit ff81f71449
25 changed files with 127 additions and 263 deletions
+3 -6
View File
@@ -57,19 +57,16 @@ class BlockLanguages extends Module
*/
function hookTop($params)
{
$context = Context::getContext();
$languages = Language::getLanguages(true, $this->shopID);
$languages = Language::getLanguages(true, $this->context->shop->getID());
if (!sizeof($languages))
return '';
$context->controller->smarty->assign('languages', $languages);
$this->context->controller->smarty->assign('languages', $languages);
return $this->display(__FILE__, 'blocklanguages.tpl');
}
function hookHeader($params)
{
$context = Context::getContext();
$context->controller->addCSS(($this->_path).'blocklanguages.css', 'all');
$this->context->controller->addCSS(($this->_path).'blocklanguages.css', 'all');
}
}