39 lines
872 B
PHP
39 lines
872 B
PHP
<?php
|
|
|
|
include(dirname(__FILE__).'/../../config/config.inc.php');
|
|
include(dirname(__FILE__).'/followup.php');
|
|
|
|
if (/*isset($_SERVER['REMOTE_ADDR']) &&*/
|
|
($_SERVER['REMOTE_ADDR'] == '90.63.178.63' || $_SERVER['REMOTE_ADDR'] == '127.0.0.1')
|
|
){
|
|
echo 'TEST1'."\n";
|
|
if (Tools::getIsset('secure_key'))
|
|
{
|
|
echo 'TEST1-1'."\n";
|
|
$secure_key = Configuration::get('PS_FOLLOWUP_SECURE_KEY');
|
|
if (!empty($secure_key) && $secure_key == Tools::getValue('secure_key'))
|
|
{
|
|
echo 'OK1'."\n";
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
echo 'TEST2'."\n";
|
|
if (Tools::getIsset('secure_key'))
|
|
{
|
|
echo 'TEST2-2'."\n";
|
|
$secure_key = Configuration::get('PS_FOLLOWUP_SECURE_KEY');
|
|
if (!empty($secure_key) && $secure_key === Tools::getValue('secure_key'))
|
|
{
|
|
echo 'OK2'."\n";
|
|
|
|
$followup = new Followup();
|
|
if ($followup->active)
|
|
$followup->cancelledCartBis();
|
|
}
|
|
}
|
|
}
|
|
|
|
echo 'END'."\n";
|
|
exit; |