Last updated 07/09/2024
Before adding the Opt-in popup (Newsletter) tool make sure you have added the initialization script tag.
Add the Opt-in popup (Newsletter) tool to any page on your site. The Opt-in popup dialog will pop up after a specified number of seconds, prompting the user to authenticate with the provider of their choice to sign up.
Bread & Butter remembers who has signed up, and won’t prompt them again. The Opt-in popup will be hidden for 24 hours for users who dismiss it without authenticating.
This guide explains how to add the Opt-in popup tool to any page on your site, and how to configure the content you want it to display, including header image.
Find the initialization script you have added to your webpage (see initialization script if you have not added it already)
In the initialization script, find the line:
BreadButter.configure({app_id: "[APP_ID]"});
Add the following line under BreadButter.configure();
BreadButter.ui.addNewsletterWidget({ custom_event_code: 'CUSTOM_EVENT_NAME', delay_seconds: DELAY_TIME_SECONDS, header_text: 'HEADER_TEXT', main_text: 'BODY_TEXT', success_header: 'SUCCESS_HEADER', success_text: 'SUCCESS_TEXT', image_type: 'IMAGE_TYPE', image_source: 'IMAGE_URL' });
Replace CUSTOM_EVENT_NAME with the user event code that you want to trigger when a user signs up. Don't have a user event or Integration and Rule set up yet? Check out Integration Setup.
For the header image, you can choose the default image, your own custom image, or no image.
You should now see the Opt-in popup tool appear on the specified page, after the specified time period.
Note: If you dismiss the Opt-in popup by clicking the X at the top right, it will be hidden for 24 hours, before appearing again on the page for that visitor.
Don’t use Bread & Butter? Want to learn more about how Bread & Butter solves the four biggest problems facing marketers today? Book a demo and see how Bread & Butter is helping marketers make the most of their first-party data
Add authentication & API event tracking to your website/app with a script tag & configuration