With this script generator, you can create custom initialization logic that runs when a certain Area is opened or closed.
How it works
- Fill out the form to generate a custom code snippet.
- Copy the final code from the “Result” box in the bottom.
- Paste the code to your website:
- When you have Area-specific code (with an Area ID) you should create a Code-Module inside that Area and paste the code into that module.
- When you have global code (no Area ID), then you can paste the code into the Theme Builder footer, a js file in your child-theme, or into the <body> field in Divi > Theme Options > Integrations.
Notes
- The form below is a “local form” that cannot be sent to our servers, the final code is generated directly in your browser.
- Read more about ways to integrate JS code here: How to use the JS API
Code Generator
Either #my-popup
, the numeric Area ID, like 2520
, or the full Area name, like divi-area-contact-form
. Leave this empty to run the code in every Area.
Enter or paste your JavaScript code here. Make sure that you do not paste the <script>
and </script>
tags in here!
// Please fill out the form above...