Workarounds & Codes

How to Detect Visitors Browser

There is certain information that we can obtain from our clients so that we can better understand them. In this case, we will show how to know if they are using a mobile or a computer. For this, we w…

Updated

Proactive message on mobile

Having troubles viewing your amazing Proactive Message on your phone? Let's get that fixed! Showing correctly the Proactive message essentially depends on the width of the device being used; in order…

Pau Sanchez
Updated by Pau Sanchez

Conditional Welcome (Non-embedded bots)

There are several instances where we may need a dynamic bot with different flow options. In this example, we'll create two different flows for our user, depending on an external parameter, in this ca…

Abby
Updated by Abby

Conditional Welcome: Direct the Flow of Your Bot Based on External Parameters

There are several instances where we may need a dynamic bot with different flow options. In this example, we'll create two different flows for our user, depending on an external parameter, in this ca…

Abby
Updated by Abby

Two-Step Email Verification

In this article we'll show you how to create a two-step email verification with a Javascript block and a SendGrid Email block. In the welcome message we've used multi-question to ask the user for the…

Abby
Updated by Abby

Detect if bot was opened

Sometimes we may want to detect if the chatbot was opened, even if the client didn't interact This will give us some insight into how many users start to interact and don't complete the interaction I…

Abby
Updated by Abby

Different ways to format numbers with JS

To see this workaround for the WhatsApp channel, review this article. Transform 1000 to 1,000 First, we ask for a number and store it in the @number variable. With a Code block we add the function th…

Ana
Updated by Ana

Trigger Event if User Abandons Chat

If a user abandons a chat there are several actions we can take to get them to re-engage. Here we will use Pipedream to trigger an HSM template for users who didn't complete the flow In this example,…

Abby
Updated by Abby

Calculate Distances in WhatsApp

In the case that we want to calculate the distance between two coordinates in WhatsApp We can use the Google Distance Matrix API if you already have a Google Cloud account, you can simply import this…

Abby
Updated by Abby

Customized Behavior in Mobile Browsers

Load different bot for mobile browsers. In some cases due to UE or content we may want to load a different bot if the user is on a mobile device In order to do this we will need to add a script to ou…

Pau Sanchez
Updated by Pau Sanchez

Trigger Event if User Abandons Chat Using AWS

If a user abandons a chat there are several actions we can take to get them to re-engage. Here we will use AWS Lambda to trigger a function, keep in mind that the following code is just an example of…

Abby
Updated by Abby

Launch Bot On Exit Intent

Here's how to launch a Popup or Livechat bot when the user is trying to leave the page: We'll insert the following script after our embed script and before the end of the script tag: function onMouse…

Abby
Updated by Abby

Display Bot During Business Hours Only (Livechat & Popup)

In the case that we only want to display the bot during business hours, we'll simply add a snippet to the Javascript of the bot (only Livechat & Popup). In this workaround we'll use the Javascript me…

Abby
Updated by Abby

Delete Customer Data in Flow

We may want to delete our customer data, after we've sent it to our CRM In this example we'll show you how to connect to Make to send an API petition to delete our customer data, after we've sent it…

Abby
Updated by Abby

Cookie consent banner (full page / full page embed)

Due to legal reasons we might need to add a legal consent banner, and ask the user for consent. Below is a handy sample code in case you want to add such functionality specially designed for Full Pag…

Pau Sanchez
Updated by Pau Sanchez

Add Captcha Verification (Non-Embedded Bots)

In this article we'll show you how to add a Captcha checkbox to non-embedded Landbots Before the user can enter the flow, or initiate a chat with our bot, they must have first completed the captcha W…

Abby
Updated by Abby

Launching a bot depending on browser language

We know how important it is to provide personalized customer service, which is why we have created this workaround to display a bot based on the language of the user's browser. You need to create a b…

Updated

Trigger a Global Keyword with JS (web v3)

Global Keywords allows you to set paths, based on a specific Keyword. Thanks to Landbot SDK we can trigger a Message via Javascript, that can trigger the sending of a message, that will trigger the g…

Pau Sanchez
Updated by Pau Sanchez

Create a Scale out of Buttons - Workaround

Sometimes we may want custom numbers in our scales, as this isn't currently an option in the scale block, you can use buttons with CSS to achieve the appearance of a scale. The builder: The CSS: /*Bu…

Abby
Updated by Abby

How to set up questions with a countdown

In this example, we will show a way to build a custom countdown timer to let the user answer in 5 seconds, if once those 5 seconds had finished and there user didn't input and send the question, the bot will continue to the next question.

Pau Sanchez
Updated by Pau Sanchez

How to pass WordPress logged in user data to Landbot

Being able to identify logged in users can be very important for some businesses and websites. We can achieve that by passing the lead's information in an identity in the embed code. We are using Wor…

Abby
Updated by Abby

Create Dynamic Shopping Cart with JS and CSS

In this article we will provide step-by-step guidelines to help you create a shopping cart that meets your needs based on an Airtable database. The example provided is a Restaurant type bot where you…

Cesar Banchio
Updated by Cesar Banchio

Set the flow depending on the url path (for embedded landbots)

Only for landbots embedded (not standalone). Do not test in Preview mode. We might want to personalise the experience of the visitor to our site with different "chatbots" depending on the section tha…

Ana
Updated by Ana

Generate a URL that has variables from user answers

It can happen that at the end of the flow you want redirect your clients to a specific website. It can be also the case that you want to generate a URL with the values provided by the users and that…

Pau Sanchez
Updated by Pau Sanchez

Resume flow based on external process with Landbot API (Request, Set, Go)

There are flows, that need an external process to be done to resume before the user can proceed. And at the same time, that process might be conditioned. For example a payment processed that is being…

Pau Sanchez
Updated by Pau Sanchez

Creating Masks for User Input (2 examples)

In this article we are going to provide 2 examples on applying masks to user's input, when we want them formatted a certain way. Date Format. Add a code block before the Text Block with the following…

Cesar Banchio
Updated by Cesar Banchio

Popup on Exit Intent

When trying to capture leads we need to use every resource available, here we'll show you how to display a popup modal when the user scrolls out of the page using the open-source Ouibounce library. T…

Abby
Updated by Abby

Contact