Publish / unpublish a pop-up form on your site

To display your form on your website, you need to add the form code to your site and publish it.

Before you start

Before activating the publication of your form, make sure you have:

  • linked your form to at least one group (open the form editor, go to Settings tab > Target groups section)
  • entered the URL of the site on which you're going to publish your form (go to Settings tab > Your website URL section)
     

    You must enter the complete URL of your website, starting with "http://" or "https://". Even if your form will only be published on a specific page of your site, enter only the first part of the URL up to its extension. For example, if the page where you're going to publish your form is "https://www.blog.mywebsite.com/category/news", enter "https://www.blog.mywebsite.com".

    If your site supports both protocols ("http://" and "https://") and you want your form to be displayed on both versions, you'll need to create a form for the "http://" version and one for the "https://" version.

  • validated your form's success message
  • saved your last changes.

Get your form code

To integrate your form on your website, you'll need to retrieve its code. Note that you don't need to have completed its configuration to add it to your site, because even if you make changes to your form, the code of its script won't change, and it won't be displayed until you activate its publication.

To retrieve the code for your form:

  • From the form editor, click on Get code. Then copy the code of your form.

    Get the form code option
  • From the list of forms, open the Icone Actions located to the right of your form and select the Get code option. Then copy the code of your form.

Integrate your form code into your website

To integrate the form on your site, you need to paste the code you copied in the previous step inside your website's <head> tag. It must be present on every page where the form should appear. For it to be displayed, don't forget to activate its publication in your account.

Display the pop-up form from a clickable element

To trigger the display of a pop-up form from a clickable element such as a hyperlink or button:  

  1. Make sure your form script has been added inside the <head> tag of the page where the clickable element is located. See previous section.
  2. In the form editor, copy the link code to be added to the element to be clicked to display your pop-up form. You'll get this code in the same place as your form script (press the button </> Get code at the top of the editor).

    Get the form code option

    get the clickable link code
  3. Insert the link on the clickable element of your website. See examples below.

Example of HTML code

In the examples below, replace the part between data-cifr-click=” andwith your form's unique identifier.

Text link

<a href="javascript:void(0)" data-cifr-click="M5LA_BqRBNN2KVmgWzz95GKdRAYt6PUS3_-6xxxxxxxxxxxxxxxxxxxf6BX30xM77J6dZX0AkS6IE8Yuzru4w~~">Texte du lien</a>

Button

<button type="button" data-cifr-click="M5LA_BqRBNN2KVmgWzz95GKdRAYt6PUS3_-6xxxxxxxxxxxxxxxxxxxf6BX30xM77J6dZX0AkS6IE8Yuzru4w~~">Bouton</button>

To trigger the display of the pop-up form on a custom event, for example to make the form appear only when specific conditions are met, you can use the following code snippet anywhere in your javascript. Don't forget to replace the ID in the example with your form's unique identifier. Like the examples of clickable elements above, you also need to ensure that your form script is present inside the <head> tag of your page.

if (cifr_loaded) {
    if (typeof window.externalCall_showForm === 'function') {
        window.externalCall_showForm("M5LA_BqRBNN2KVmgWzz95GKdRAYt6PUS3_-6xxxxxxxxxxxxxxxxxxxf6BX30xM77J6dZX0AkS6IE8Yuzru4w~~");
    }
}

Publish your form

  1. From the form editor, activate the switch at the top right of the editor.

    Activate the switch to publish your form
  2. Save your latest changes.
  3. If necessary, copy the form code to be integrated into your website. Then confirm publication by clicking on Publish.

    Popup de confirmation pour activer la publication de votre formulaire

Unpublish your form

If you need to make changes to your form, or simply want to stop displaying it on your site without having to immediately remove the code from your form, you can simply unpublish it.

To do this:

  1. From the form editor, deactivate the switch at the top right of the editor.

    Désactiver l'interrupteur pour dépublier votre formulaire
  2. Then confirm that you wish to stop publication.

    Confirmer pour arrêter la publication

You can also quickly activate or deactivate the publication of your form via the switch available in the list of your forms.

publish or unpublish your form from the forms' listing

See also:

 

Top