diff --git a/htdocs/comm/mailing/card.php b/htdocs/comm/mailing/card.php index ce260a44a35..42bac2af7e5 100644 --- a/htdocs/comm/mailing/card.php +++ b/htdocs/comm/mailing/card.php @@ -2,6 +2,7 @@ /* Copyright (C) 2004 Rodolphe Quiedeville * Copyright (C) 2005-2019 Laurent Destailleur * Copyright (C) 2005-2016 Regis Houssin + * Copyright (C) 2021 Waƫl Almoman * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -244,6 +245,9 @@ if (empty($reshook)) { $substitutionarray['__SECUREKEYPAYMENT_CONTRACTLINE__'] = dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.'contractline'.$obj->source_id, 2); } } + if (!empty($conf->global->MEMBER_ENABLE_PUBLIC)) { + $substitutionarray['__PUBLICLINK_NEWMEMBERFORM__'] = ''.$langs->trans('BlankSubscriptionForm'). ''; + } /* For backward compatibility, deprecated */ if (!empty($conf->paypal->enabled) && !empty($conf->global->PAYPAL_SECURITY_TOKEN)) { $substitutionarray['__SECUREKEYPAYPAL__'] = dol_hash($conf->global->PAYPAL_SECURITY_TOKEN, 2); diff --git a/htdocs/core/class/html.formmail.class.php b/htdocs/core/class/html.formmail.class.php index 96f6ee0a741..a9da488907d 100644 --- a/htdocs/core/class/html.formmail.class.php +++ b/htdocs/core/class/html.formmail.class.php @@ -1633,6 +1633,9 @@ class FormMail extends Form $vars['__SECUREKEYPAYMENT_CONTRACTLINE__']=''; */ } + if (!empty($conf->global->MEMBER_ENABLE_PUBLIC)) { + $substitutionarray['__PUBLICLINK_NEWMEMBERFORM__'] = 'BlankSubscriptionForm'; + } } foreach ($tmparray as $key => $val) {