SMF·OPINION-STAGE
Can a prompt replace Opinion Stage?
Forms & surveys — forms, surveys and lead capture
Exhibit tracking slip
Verdict
A poll widget is one of the genuinely small builds in this catalogue: a question, image answers, a vote, a result bar. What makes it worth building rather than pasting a third-party script is that the votes are yours and the embed does not carry a tracker onto a reader's page. There is no third-party dependency anywhere in the loop, and a working version fits in one sitting.
Exhibit A — The prompt
Received on31.07.2026Build an embeddable poll and quiz widget with results stored in your own database.
Item types, two only:
- Poll: one question, two or more answers, each with optional image. One vote per visitor. After voting, the reader sees the distribution as bars with percentages and a total count.
- Quiz: several questions with one correct answer each, optional image per answer. At the end, a score and an outcome message chosen from ranges the author defines.
Authoring: a simple builder with question text, answers, images uploaded locally and resized to a few responsive sizes, and per-item settings — whether to show results before voting, whether to allow changing a vote, and an open and close date.
The embed: one script served from your own domain, dropped into any page with a container element carrying the item id. It must render inside a shadow root so the host page's CSS cannot break it and its own styles cannot leak, size itself to its content, work without any framework on the host page, and be under 20 KB compressed. Provide a no-JavaScript fallback that renders a link to the poll's own page, so a reader with scripts disabled sees something.
Voting integrity, proportionate to the stakes: one vote per browser enforced with a localStorage marker plus a server-side check on a daily-rotating hash of the IP and user agent. Rate-limit per address. Do not set a persistent cookie and do not store a raw IP — a poll widget does not need to identify anyone, and one that does is a liability on somebody else's page.
Results: live bars updating for the voter without a page reload, using a single poll of the results endpoint rather than a socket. The author's dashboard shows totals, votes over time, and the referring page each vote came from where the browser supplied one.
CORS: the results and voting endpoints accept requests only from an allowlist of origins configured per item, so the poll cannot be embedded and voted on elsewhere.
Export: results as CSV, and the item definition as JSON so a poll can be duplicated.
Accessibility: real radio inputs with labels, keyboard operable, results announced to assistive technology after voting. An embedded widget that is not keyboard operable makes the host page worse.
Out of scope: lead capture and gating results behind an email, CRM integrations, audience benchmarking against other sites, and a template marketplace.
Opening prefills the prompt — press enter to run it.
Exhibit B — What you lose
- B.1 the template library and its designed poll layouts
- B.2 the lead-capture and CRM integrations after a quiz result
- B.3 audience-comparison features that show how you scored against everyone else
- B.4 hosted delivery — an embed that fails is now your problem
Prior art
Exhibit C — Why people still pay: integrations, deliverability, and workflow depth
Because publishers embed these across hundreds of articles and need them to render everywhere, always. Reliability across every theme and browser is what the price covers, not the voting logic.
Questions
Can I export my Opinion Stage results?
Results export as CSV, so the historical numbers come with you. The poll definitions do not export in a reusable form, but they are quick to re-create — a poll is a question and four answers.
Will the embed break my page?
The shadow root is what prevents that in both directions, and it is why the prompt insists on it. The other half is size: a 20 KB script loaded asynchronously does not measurably affect a page, whereas the typical third-party widget in this category ships several hundred kilobytes and a tracker.
What does it cost to run?
A small VPS with a database, five to ten dollars a month, serving as many polls across as many articles as you like. Vote records are tiny, so the cost does not scale with traffic in any meaningful way.
What is the one thing that does not survive the rebuild?
Somebody else's uptime. A poll embedded in two hundred articles is now part of your site's critical path, and when your server has a bad night it is your readers who see the gap.
Related tools
Receipt