bebeboutik/modules/privatesales/showsale.php

18 lines
521 B
PHP
Raw Normal View History

2016-01-04 12:49:26 +01:00
<?php
// Compatiblity controller to handle old sale URLs
include(dirname(__FILE__).'/../../config/config.inc.php');
include(dirname(__FILE__).'/../../init.php');
if($id_sale = Tools::getValue('id_sale')) {
if($sale = Db::getInstance()->getRow('
SELECT `id_category`
FROM `'._DB_PREFIX_.'privatesale`
WHERE `id_sale` = '.(int) $id_sale.'
')) {
Tools::redirectLink($link->getCategoryLink(new Category((int) $sale['id_category'], (int) $cookie->id_lang), NULL, (int) $cookie->id_lang));
}
}
Tools::redirect();