Page tree

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 25 Next »

L’équipe SecuTix Gravity est enchantée de pouvoir présenter aujourd’hui l’un de nos tout premiers widgets, le Newsletter Widget ! Il s’agit d’un simple extrait de code que vous pouvez facilement intégrer à votre site Web. Jusqu’à présent, vos clients en ligne ne pouvaient s’inscrire à votre newsletter sur la plateforme de vente en ligne SecuTix que s’ils créaient un compte ou faisaient un achat comme visiteur. Avec ce widget, ils auront désormais la possibilité de s’abonner à votre newsletter à partir de n’importe quel site le contenant. Cet outil flexible, hautement personnalisable et facile à intégrer peut largement contribuer à augmenter la présence en ligne de votre newsletter.

Veuillez noter que cet article ne s’applique qu’à la version 1 du SecuTix Gravity Newsletter Widget publié dans PizBernina V2.

How does it work?

To use a newsletter widget, first you would need to integrate a code snippet into your target website. You may either contact your web agency to embed the snippet into your website's HTML code or integrate it via Google Tag Manager. The code snippet will first call SecuTix back-end service to fetch the necessary configurations (e.g. theme and labels) and then render the user interface of the widget based on the configuration. You can put the widget anywhere in your website, e.g., inside a popup, inside the footer or on the secondary column of your website, just to name a few. The user interface of this widget contains a simple form with various fields (e.g. email address, civility, first name and last name) and a submit button. Its default style and theme are the same as the ones from the corresponding online sales platform.

Once your online customers fill in the necessary information inside the widget and click the submit button, the newsletter widget will call SecuTix back-end service to check whether an account already exists with the given email address. If not, a new account will be created inside SecuTix with the provided user information and future newsletters will be sent to the given email address. If the email is already in use, the newsletter widget will display an error message and a link which points to the login page of the corresponding online sales platform.

Example

Below is an example of the newsletter widget integrated as a popup inside the demo site.

Sample code snippet

Sample code
<div id="stx-newsletter"></div>
<script type="text/javascript" src="https://s3.eu-central-1.amazonaws.com/pub.tnwi.p16-s3.secutix.com/stx-widgets/Newsletter/v1/Newsletter.js"></script>
<script type="text/javascript">
	STX.config({apiKey:"8bafa660-8bc1-4982-83da-f15fce01f4ec", hostname:"hostname of your online sales platform"});
	STX.widgets.Newsletter.render({props:{activeFields: ['civility', 'firstName', 'lastName']}, locale: "fr", root:"#stx-newsletter"});
</script>

Parameters

  • apiKey - the secret token generated in your point of sales configuration screen. You may find this parameter in the Sales Channels > Point of sales > Characteristics > Internet Parameters tab.

  • hostname - the hostname of the point of sales URL for your online sales platform. 

    Please note that the newsletter widget will fetch the configurations (e.g. theme and labels) from the corresponding point of sales.

  • activeFields - (Optional) an array where you can specify which fields you want to display in your newsletter widget. Supported fields are "civility", "firstName" and "lastName". 

    Please note that an email field is always displayed regardless of the activeFields values.

  • locale - (Optional) the language code which defines the language of the newsletter widget. When not set, the widget will use the main institution language by default. 

Legal mention

If you would like to display legal mention inside the newsletter widget, you can do so by using the label overriding mechanism from the light customization screen of the corresponding online sales platform's point of sales.

Google reCAPTCHA

Since the Newsletter Widget will actually create a user account inside your SecuTix system, in order to prevent potential security issues, we integrated Google's invisible reCAPTCHA into the widget. If you encounter an error saying "Invalid domain for site key" while integrating the Newsletter Widget, that just means your website is not in the authorized white list for our Google reCAPTCHA account. Please contact our support team to add your site into our white list.

  • No labels