# Subscriptions

Choose from 4 different opt-in types in the edrone panel.

Type Description
edrone double opt-in Double Opt-In provided by edrone.
non edrone double opt-in Double Opt-In provided by some other system or store.
single opt-in with message Single Opt-In with welcome message.
single opt-in Single Opt-In without welcome message.

Subscription - Use the subscribe action to send the information about customer subscription.

Example

<script>
const submitButton = document.querySelector('#submit-button');

if (submitButton) {
    submitButton.addEventListener('click', function() {
        _edrone.customer_tags = 'From PopUp';
        _edrone.email = document.querySelector('#input-email')?.value ?? '';
        _edrone.first_name = document.querySelector('#input-name')?.value ?? '';
        _edrone.action_type = 'subscribe';
        _edrone.init();
    });
}
</script>

  • document.querySelector('#submit-button') - identifier of the subscription form button
  • document.querySelector('#input-email')?.value; - value of the email field
  • document.querySelector('#input-name')?.value; - value of the first name field