Merge branch 'develop' of gitlab.antadis.net:dev-antadis/bebeboutik into develop

This commit is contained in:
root 2017-05-04 16:35:46 +02:00
commit c7754f5793
2 changed files with 10 additions and 3 deletions

View File

@ -19,6 +19,10 @@ if(($sponsor = Tools::getValue('sponsor')) && strlen($sponsor) > 12) {
} }
$url = parse_url($_SERVER['REQUEST_URI']); $url = parse_url($_SERVER['REQUEST_URI']);
if(Tools::getIsset('lpes')) {
$lp = Tools::getValue('lpes');
Tools::redirect('?sponsor='.rawurlencode($cipherTool->encrypt('1|'.$email.'|')).(isset($lp)? '&lpes='.$lp: ''));
}
if(Tools::getIsset('lp')) { if(Tools::getIsset('lp')) {
$lp = Tools::getValue('lp'); $lp = Tools::getValue('lp');

View File

@ -25,14 +25,17 @@
{*<span class="form_info">{l s='(5 characters min.)'}</span>*} {*<span class="form_info">{l s='(5 characters min.)'}</span>*}
</p> </p>
{$HOOK_CREATE_ACCOUNT_FORM} <p class="required referralprogram">
<label for="referralprogram_lp">{l s='E-mail address of your sponsor' mod='landingpages'}</label>
<input type="text" size="52" maxlength="128" class="text" id="referralprogram_lp" name="invite" value="{if isset($sponsor_email)}{$sponsor_email|escape:'htmlall':'UTF-8'}{elseif isset($smarty.post.invite)}{$smarty.post.invite|escape:'htmlall':'UTF-8'}{elseif isset($referralprogram)}{$referralprogram|escape:'htmlall':'UTF-8'}{/if}" />
</p>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function() {
var mail = $("#referralprogram").val(); var mail = $("#referralprogram_lp").val();
var data = mail.split('@'); var data = mail.split('@');
if(data[1] == 'bebeboutik.com'){ if(data[1] == 'bebeboutik.com'){
$("#referralprogram").parent().hide(); $("#referralprogram_lp").parent().hide();
} }
}); });
</script> </script>