';
+ if (Context::shop() == Shop::CONTEXT_GROUP)
+ printf(translate('You are configuring your store for group shop %s'), ''.Context::getContext()->shop->getGroup()->name.'');
+ elseif (Context::shop() == Shop::CONTEXT_SHOP)
+ printf(translate('You are configuring your store for shop %s'), ''.Context::getContext()->shop->name.'');
+ echo '
';
+ }
+
+ if (Validate::isLoadedObject($adminObj))
+ {
+ if ($adminObj->checkToken())
+ {
+ /* Filter memorization */
+ if (isset($_POST) AND !empty($_POST) AND isset($adminObj->table))
+ foreach ($_POST AS $key => $value)
+ if (is_array($adminObj->table))
+ {
+ foreach ($adminObj->table AS $table)
+ if (strncmp($key, $table.'Filter_', 7) === 0 OR strncmp($key, 'submitFilter', 12) === 0)
+ $cookie->$key = !is_array($value) ? $value : serialize($value);
+ }
+ elseif (strncmp($key, $adminObj->table.'Filter_', 7) === 0 OR strncmp($key, 'submitFilter', 12) === 0)
+ $cookie->$key = !is_array($value) ? $value : serialize($value);
+
+ if (isset($_GET) AND !empty($_GET) AND isset($adminObj->table))
+ foreach ($_GET AS $key => $value)
+ if (is_array($adminObj->table))
+ {
+ foreach ($adminObj->table AS $table)
+ if (strncmp($key, $table.'OrderBy', 7) === 0 OR strncmp($key, $table.'Orderway', 8) === 0)
+ $cookie->$key = $value;
+ }
+ elseif (strncmp($key, $adminObj->table.'OrderBy', 7) === 0 OR strncmp($key, $adminObj->table.'Orderway', 12) === 0)
+ $cookie->$key = $value;
+ $adminObj->displayConf();
+ $adminObj->postProcess();
+ $adminObj->displayErrors();
+ $adminObj->display();
+ }
+ else
+ {
+ // If this is an XSS attempt, then we should only display a simple, secure page
+ ob_clean();
+
+ // ${1} in the replacement string of the regexp is required, because the token may begin with a number and mix up with it (e.g. $17)
+ $url = preg_replace('/([&?]token=)[^&]*(&.*)?$/', '${1}'.$adminObj->token.'$2', $_SERVER['REQUEST_URI']);
+ if (false === strpos($url, '?token=') AND false === strpos($url, '&token='))
+ $url .= '&token='.$adminObj->token;
+
+ $message = translate('Invalid security token');
+ echo ''.$message.'
+
'.translate('A new order has been made on your shop.').' '.translate('Order number : ').'#" + parseInt(value.id_order) + " '.translate('Total : ').'" + value.total_paid_real + " '.translate('From : ').'" + value.customer_name + " '.translate('Click here to see that order').'
";
+ html += "
'.translate('A new order has been made on your shop.').' '.translate('Order number : ').'#" + parseInt(value.id_order) + " '.translate('Total : ').'" + value.total_paid_real + " '.translate('From : ').'" + value.customer_name + " '.translate('Click here to see that order').'
";
});
if (html != "")
{
@@ -94,7 +94,7 @@ echo '
html = "";
nb_notifs = 0;
$.each(json.customer, function(property, value) {
- html += "
";
});
if (html != "")
{
@@ -113,7 +113,7 @@ echo '
html = "";
nb_notifs = 0;
$.each(json.message, function(property, value) {
- html += "
'.translate('A new message posted on your shop.').' '.translate('From : ').'" + value.customer_name + " '.translate('Excerpt : ').'" + value.message_customer + " '.translate('Click here to see that message').'
";
+ html += "
'.translate('A new message posted on your shop.').' '.translate('From : ').'" + value.customer_name + " '.translate('Excerpt : ').'" + value.message_customer + " '.translate('Click here to see that message').'
";
});
if (html != "")
{
@@ -192,7 +192,7 @@ echo ' var html = "";
'.translate('Last orders').'
'.translate('No new orders has been made on your shop').'