WordPress
Put Orvelt's opinion form on a WordPress page or post with a Custom HTML block.
WordPress's block editor has a Custom HTML block that accepts your block as-is.
Before you start:
- Have your Project ID ready and choose feedback button or form on the page. How to get these
- On WordPress.com, adding scripts requires a plan that allows custom code. Self-hosted WordPress (WordPress.org) sites can add it on any setup. Some security plugins remove scripts from posts; if the form doesn't appear, check yours.
1. Copy your block
Replace PASTE-YOUR-PROJECT-ID-HERE with your Project ID.
<button id="orvelt-feedback-button" type="button">Give feedback</button>
<script src="https://unpkg.com/@orvelt/business/dist/opinion-embed.js"></script>
<script>
(function () {
var form = OrveltEmbed.configure({
projectId: 'PASTE-YOUR-PROJECT-ID-HERE',
visibility: 'public',
});
document.getElementById('orvelt-feedback-button').addEventListener('click', function () {
form.open();
});
})();
</script>2. Paste it into your page
In your WordPress dashboard, open the page or post where the form should appear, or create a new one.
Select the + (block inserter) where the form should go, search for Custom HTML, and add it.
Paste your block into the Custom HTML block.
Select Update (or Publish for a new page).
Using the Classic editor or a page builder?
In the Classic editor, switch to the Text tab before pasting. In Elementor, Divi, and similar builders, use their HTML or Code widget.
3. Test it
Open the published page in a new tab and submit a test opinion. The block editor's preview may not run scripts. Test the form