146 lines
6.9 KiB
PHP
146 lines
6.9 KiB
PHP
<?php
|
|
|
|
global $panier, $vDomaine, $strLangue, $tabEvenement;
|
|
|
|
switch ($p) {
|
|
case 'success':
|
|
if (isset($_SESSION['ancien_no_panier']))
|
|
fxMajEpreuvesCommandees($_SESSION['ancien_no_panier'], $_SESSION['pec_id_old'], $_SESSION['pec_id_new'], $_SESSION['no_transfert']);
|
|
|
|
// couleurs par défaut
|
|
$strColor = 'f3a566';
|
|
$intGratuit = (isset($tabEvenement)) ? $tabEvenement['general']['eve_gratuit'] : 0;
|
|
|
|
// couleur du client
|
|
if (isset($tabEvenement) && trim($tabEvenement['general']['eve_couleur']) != '') {
|
|
$strColor = str_replace('#', '', $tabEvenement['general']['eve_couleur']);
|
|
}
|
|
|
|
if (fxGetVariable('confirm_mail') == '0') {
|
|
?>
|
|
<div class="alert alert-info">
|
|
<strong>
|
|
<?php afficheTexte('resultat_delai_confirmation_mail'); ?>
|
|
</strong>
|
|
</div>
|
|
<?php
|
|
}
|
|
|
|
if (intval($intGratuit) == 1) { // si événement gratuit
|
|
?>
|
|
<h1><?php if ($strLangue == 'fr') { ?>Inscription confirmée<?php } else { ?>Registration confirmed<?php } ?></h1>
|
|
<p>
|
|
<?php
|
|
if ($strLangue == 'fr') {
|
|
?>
|
|
Votre numéro de confirmation est le <strong><?php echo $commande; ?></strong>. Vous recevrez d'ici peu un courriel confirmant votre inscription chez <?php echo $vClient; ?>.
|
|
<?php
|
|
} else {
|
|
?>
|
|
Your confirmation number is <strong><?php echo $commande; ?></strong>. You will shortly receive an email confirming your registration with <?php echo $vClient; ?>.
|
|
<?php
|
|
}
|
|
?>
|
|
</p>
|
|
<?php
|
|
} else { // si événement normal
|
|
?>
|
|
<h1><?php if ($strLangue == 'fr') { ?>Transaction acceptée<?php } else { ?>Transaction accepted<?php } ?></h1>
|
|
<p>
|
|
<?php
|
|
if ($strLangue == 'fr') {
|
|
?>
|
|
Votre numéro de confirmation est le <strong><?php echo $commande; ?></strong>. Vous recevrez d'ici peu un courriel confirmant votre transaction chez <?php echo $vClient; ?>.
|
|
<br>La charge de cette transaction sera portée à votre relevé de carte de crédit sous le nom de : INSCRIP MS1.
|
|
<?php
|
|
} else {
|
|
?>
|
|
Your confirmation number is <strong><?php echo $commande; ?></strong>. You will shortly receive an email confirming your transaction with <?php echo $vClient; ?>.
|
|
<br>This transaction will appear on your credit card statement under the business name of: INSCRIP MS1.
|
|
<?php
|
|
}
|
|
?>
|
|
</p>
|
|
<?php
|
|
}
|
|
|
|
// récupérer les variables pour le partage sur facebook
|
|
$tabData = fxGetTextFacebook($panier, $strLangue);
|
|
$tabParam = fxGetFacebookParam($tabData);
|
|
/*?>
|
|
<p class="facebook_dialog">
|
|
<a id="fb_share" class="btn btn-primary rounded-0" href="<?php echo fxGetFacebookLink($tabParam); ?>">
|
|
<i class="fa fa-facebook-square mr-2" aria-hidden="true"></i>
|
|
<?php if ($strLangue == 'fr') { ?>Partagez sur facebook<?php } else { ?>Share on facebook<?php } ?>
|
|
</a>
|
|
</p>
|
|
<?php*/
|
|
$arrLinks = fxGetLinksDonation($panier,$strLangue);
|
|
echo fxShowLinksDonation('web', $arrLinks, $strLangue, $strColor);
|
|
?>
|
|
<div class="text-right mb-2">
|
|
<a class="btn btn-primary rounded-pill" href="<?php echo $vDomaine; ?>/facture.php?no_panier=<?php echo $panier; ?>&lang=<?php echo $strLangue; ?>" target="_blank">
|
|
<i class="fa fa-print mr-2" aria-hidden="true"></i>
|
|
<?php if ($strLangue == 'fr') { ?>Imprimer<?php } else { ?>Print<?php } ?>
|
|
</a>
|
|
</div>
|
|
<?php
|
|
// Afficher les détails de la conmmande
|
|
echo fxShowAddress($panier, 'web', $strLangue);
|
|
echo fxShowPanier($panier, 0, 'web', 1, $strLangue);
|
|
echo fxUpdateLiensInternes(fxShowAdresseMagasin($panier, $strLangue));
|
|
echo fxShowTermesAcceptes($panier, $strLangue);
|
|
|
|
if (isset($_SESSION['com_id'])) {
|
|
if ($tabEvenement['general']['te_id'] != 9) {
|
|
if ($strLangue == 'fr') {
|
|
$strPageCompte = 'compte';
|
|
} else {
|
|
$strPageCompte = 'account';
|
|
}
|
|
?>
|
|
<a class="btn btn-primary rounded-pill" href="<?php echo $vDomaine; ?>/<?php echo $strPageCompte; ?>">
|
|
<i class="fa fa-user mr-2" aria-hidden="true"></i>
|
|
<?php afficheTexte('resultat_reminder-noinvitation-bouton'); ?>
|
|
</a>
|
|
<?php
|
|
}
|
|
}
|
|
?>
|
|
<script type="text/javascript">
|
|
$('#fb_share').click(function(e) {
|
|
e.preventDefault();
|
|
FB.ui({
|
|
method: 'share',
|
|
quote: '<?php echo $tabParam['quote']; ?>',
|
|
href: '<?php echo $tabParam['link']; ?>',
|
|
redirect_url: '<?php echo $tabParam['redirect_url']; ?>'
|
|
}, function(response){
|
|
console.log(response);
|
|
});
|
|
});
|
|
</script>
|
|
<?php
|
|
break;
|
|
case 'cancel':
|
|
case 'error':
|
|
?>
|
|
<h1 style="color:#c33; font-style: italic; font-weight: bold;"><?php if ($strLangue == 'fr') { ?>Erreur<?php } else { ?>Error<?php } ?></h1>
|
|
<p style="color:#c33; font-style: italic; font-weight: bold;"><?php if ($strLangue == 'fr') { ?>Une erreur est survenue ou vous avez annulé votre commande.<?php } else { ?>An error has occurred or you have canceled your order.<?php } ?></p>
|
|
<div class="mb-2">
|
|
<a class="btn btn-primary rounded-pill" href="<?php echo $vDomaine; ?>/<?php if ($strLangue == 'fr') { ?>panier<?php } else { ?>cart<?php } ?>/checkout/<?php echo $_SESSION['eve_label_url']; ?>/">
|
|
<?php if ($strLangue == 'fr') { ?>Essayez de nouveau<?php } else { ?>Try again<?php } ?>
|
|
</a>
|
|
</div>
|
|
<div class="text-right mb-2">
|
|
<a class="btn btn-primary rounded-pill" href="<?php echo $vDomaine; ?>/facture.php?no_panier=<?php echo $panier; ?>&lang=<?php echo $strLangue; ?>" target="_blank">
|
|
<i class="fa fa-print mr-2" aria-hidden="true"></i>
|
|
<?php if ($strLangue == 'fr') { ?>Imprimer<?php } else { ?>Print<?php } ?>
|
|
</a>
|
|
</div>
|
|
<?php
|
|
// Afficher les détails de la conmmande
|
|
echo fxShowAddress($panier, 'web', $strLangue);
|
|
echo fxShowPanier($panier, 0, 'web', 1, $strLangue);
|
|
break;
|
|
}
|