Website FORM

Automatic translation. View original

COPY-PASTE

HEAD:

<script type="module" src="https://crm.derose.app/cors/whatsapp-form/whatsapp-form.js"></script>

BODY:

<div data-controller="whatsapp-form"
       data-whatsapp-form-phone-value="NUMERO_WHATSAPP_QUE_RECEBE_A_MENSAGGEM"
       data-whatsapp-form-padma-api-key-value="API_KEY">
    <form data-whatsapp-form-target="form"
          data-action="whatsapp-form#submit"
          class="form p-3">
      <div class="mb-2">
        <label class="form-label" for="fullName">Nombre</label>
        <input type="text" id="fullName" name="fullName" class="form-control" data-whatsapp-form-target="requiredField">
        <div class="invalid-feedback">
          Por favor ingresá tu nombre
        </div>
      </div>
      <div class="mb-3">
        <label class="form-label w-100 text-center">Fecha de nacimiento</label>
        <div class="d-flex flex-row gap-1 justify-content-center">
          <div>
            <label class="form-label" for="birthday_day">Día</label>
            <input type="number" id="birthday_day" name="birthday_day" class="form-control" data-whatsapp-form-target="requiredField">
          </div>
          <div>
            <label class="form-label" for="birthday_month">Mes</label>
            <input type="number" id="birthday_month" name="birthday_month" class="form-control" data-whatsapp-form-target="requiredField">
          </div>
          <div>
            <label class="form-label" for="birthday_year">Año</label>
            <input type="number" id="birthday_year" name="birthday_year" class="form-control" data-whatsapp-form-target="requiredField">
          </div>
        </div>
        <div class="invalid-feedback">
          Por favor ingresá tu fecha de nacimiento
        </div>
      </div>
      <div class="mb-3">
        <label class="form-label" for="email">Email</label>
        <input type="email" id="email" name="email" class="form-control" data-whatsapp-form-target="requiredField">
        <div class="invalid-feedback">
          Por favor ingresá tu email
        </div>
      </div>
      <div class="mb-3">
        <label class="form-label" for="telephone">WhatsApp</label>
        <input type="tel" id="telephone" name="telephone" class="form-control" data-whatsapp-form-target="requiredField">
        <div class="invalid-feedback">
          Por favor ingresá tu WhatsApp
        </div>
      </div>
      <div class="mb-3">
        <label class="form-label w-100 text-center">¿Cómo nos conociste?</label>
        <div class="d-flex flex-row flex-wrap justify-content-md-center">
          <div class="form-check me-4 mb-1">
            <input class="form-check-input" type="checkbox" value="1" id="instagram" name="instagram">
            <label class="form-check-label" for="instagram">
              Instagram
            </label> -
          </div>
          <div class="form-check me-4 mb-1">
            <input class="form-check-input" type="checkbox" value="1" id="googleMaps" name="googleMaps">
            <label class="form-check-label" for="googleMaps">
              Google Maps
            </label> -
          </div>
          <div class="form-check me-4 mb-1">
            <input class="form-check-input" type="checkbox" value="1" id="recommended" name="recommended">
            <label class="form-check-label" for="recommended">
              Me recomendaron
            </label> -
          </div>
          <div class="form-check me-4 mb-1">
            <input class="form-check-input" type="checkbox" value="1" id="other" name="other">
            <label class="form-check-label" for="other">
              Otro
            </label> -
          </div>
        </div>
      </div>
      <button type="submit" class="btn btn-primary w-100">Enviar datos e ir a WhatsApp</button>
    </form>
    <div class="alert alert-info hide" data-whatsapp-form-target="redirectingMessage">
      Te estamos redireccionando a nuestro WhatsApp...
    </div>
  </div>

CUSTOMIZATIONS

The inputs with data-whatsapp-form-target="requiredField" are required. The form will not be sent if these fields are empty.

In data-whatsapp-form-phone-value you must enter the whatsapp number that RECEIVES the messages.

IN data-whatsapp-form-padma-api-key-value you must enter an api-key with access ‘form_integration’. See How to generate and manage API keys of your school

Back to CRM API

Contact support