FIX : New adherent from, always redirect on entity

This commit is contained in:
Florian HENRY 2015-10-05 15:20:55 +02:00
parent fd29bb34be
commit c9d8e041d5

View File

@ -304,7 +304,6 @@ if ($action == 'add')
$urlback=DOL_MAIN_URL_ROOT.'/public/paybox/newpayment.php?from=membernewform&source=membersubscription&ref='.$adh->ref;
if (price2num(GETPOST('amount'))) $urlback.='&amount='.price2num(GETPOST('amount'));
if (GETPOST('email')) $urlback.='&email='.urlencode(GETPOST('email'));
if (! empty($entity)) $urlback.='&entity='.$entity;
}
else if ($conf->global->MEMBER_NEWFORM_PAYONLINE == 'paypal')
{
@ -315,7 +314,7 @@ if ($action == 'add')
{
$urlback.='&securekey='.dol_hash($conf->global->PAYPAL_SECURITY_TOKEN . 'membersubscription' . $adh->ref, 2);
}
if (! empty($entity)) $urlback.='&entity='.$entity;
}
else
{
@ -324,6 +323,7 @@ if ($action == 'add')
}
}
if (! empty($entity)) $urlback.='&entity='.$entity;
dol_syslog("member ".$adh->ref." was created, we redirect to ".$urlback);
Header("Location: ".$urlback);
exit;