📊
Pollz
  • Introduction
  • Quickstart
  • Guides
    • Initializing your app
    • Create a Poll
    • Vote for a Poll
    • Retrieve a Poll
    • Manage Poll Options
    • Listen to update
    • Anonymous Poll
  • Components
    • React
    • React Native
    • Embedded
  • API Reference
    • init()
    • pollOptions()
      • addOption()
      • deleteOption()
      • renameOption()
    • anonymous
      • createAnonymousToken()
      • getAnonymousPoll()
      • voteAnonymously()
    • polls
      • create()
      • get()
      • getAll()
      • vote()
      • rename()
      • deleteOne()
      • listen()
    • pollTypes
      • getAll()
  • Tooling
    • Typescript
    • React
      • usePoll()
      • usePolls()
      • usePollz()
      • usePollTypes()
      • useAnonymousPoll()
Powered by GitBook
On this page
  • Embedding Pollz Polls in Your Web Page
  • Embedding Example
  1. Components

Embedded

Embedding Pollz Polls in Your Web Page

Pollz provides an easy way to embed polls directly into your web page using a simple URL. You can use the following format:

https://getpollz.io/embed/{anonymousPollToken}

Replace {anonymousPollToken} with the actual anonymous voting token for the specific poll you want to embed.

Embedding Example

Let's say you have an anonymous voting token 'abc123' for a poll. To embed this poll in your web page, you would use the following URL:

https://getpollz.io/embed/abc123

You can include this URL in an iframe tag within your HTML to seamlessly integrate the poll into your website.

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Embedded Poll</title>
</head>
<body>
  <!-- Embedded Poll -->
  <iframe src="https://getpollz.io/embed/abc123" width="100%" height="600" frameborder="0" allowtransparency="true" allow="encrypted-media"></iframe>
</body>
</html>

Adjust the width and height attributes of the iframe according to your layout preferences.

By embedding polls directly into your web page, you can seamlessly integrate Pollz functionality, allowing users to participate in polls without navigating away from your site.

PreviousReact NativeNextAPI Reference

Last updated 1 year ago