Common Ninja widgets are a great way to enhance your Odoo website with interactive features like forms, galleries, countdown timers, reviews, and more. Depending on your Odoo setup, there are two ways to embed a widget: using the standard JavaScript embed code (recommended) or using an iframe as a fallback.
This guide will walk you through both methods.
Step 1: Create & Publish Your Widget
-
Log in to your Common Ninja dashboard.
-
Create or open the widget you want to embed.
-
Once you’re ready, click “Publish” in the top-right corner.
-
Copy either the:
-
Standard Embed Code (JavaScript snippet) – recommended for full functionality
-
Iframe Code – use only if your Odoo site does not allow scripts
-
Step 2: Determine Your Odoo Hosting Type
-
Odoo Online (SaaS) – Hosted by Odoo directly. Usually restricts JavaScript, so iframe may be the only option.
-
Odoo.sh or Self-Hosted – Gives you full control, allowing use of JavaScript (recommended).
Step 3: Add the Widget to Your Odoo Website
- For Odoo.sh or Self-Hosted (Use JavaScript Embed Code)
-
-
Go to your Odoo Website Editor and open the page where you want to add the widget.
-
Click Edit, then drag in an HTML block (or edit the template if you have access).
-
Paste the JavaScript embed code from Common Ninja.
-
Click Save and Publish the changes.
Best functionality and full widget support.
-
- For Odoo Online (Use iFrame Code)
-
-
Go to your Odoo Website Editor and open the desired page.
-
Click Edit and add an HTML block.
-
Paste the iframe code from Common Ninja.
-
Save and publish your changes.
Note: Some advanced features (like popups) may not work properly in an iframe.
-
Step 4: Test on Mobile and Desktop
After embedding, be sure to:
-
Check how the widget looks on both desktop and mobile.
-
Adjust dimensions manually if using an iframe.
-
Enable "responsive" settings from the widget editor if available.
💡 Tips & Troubleshooting
-
If the widget doesn't appear or is blank, double-check if your Odoo version allows custom scripts.
-
For iframe users: keep the dimensions appropriate to prevent display issues.
-
If you’re unsure which version of Odoo you're using, ask your developer or hosting provider.
Comments
0 comments
Please sign in to leave a comment.