Democracy Poll
Add to ListThis plugin provides an intuitive and powerful system to create various polls with features like:
- Single and multiple voting options (customizable).
- Allowing visitors to add new answers (customizable).
- Setting an end date for polls.
- Restricting voting to registered users (customizable).
- Multiple poll designs.
- And more! See the changelog for details.
Democracy Poll is compatible with all major cache plugins, including WP Total Cache, WP Super Cache, WordFence, Quick Cache, etc.
Designed for ease of use and performance, it offers:
- A “Quick Edit” button for admins, directly above a poll.
- A plugin menu in the toolbar.
- Inline inclusion of CSS & JS.
- Loading CSS & JS only when necessary.
- And more! Check out the changelog for details.
More Info
Democracy Poll is a modernized version of an earlier, well-regarded plugin by the same name. Although the original plugin by Andrew Sutherland hadn’t been updated since 2006, it introduced the innovative concept of allowing users to add their own answers. This version retains the core idea and name but features completely rewritten code.
Key features include:
- Creating new polls.
- Compatibility with cache plugins like WP Total Cache and WP Super Cache.
- Allowing users to add their own answers (optional).
- Multi-voting, enabling users to select multiple answers (optional).
- Automatically closing polls after a pre-set end date.
- Displaying random polls when multiple are available.
- Restricting polls to registered users (optional).
- Convenient admin tools, such as an “Edit” button for quick poll management.
- Editing the number of votes.
- Allowing users to change their votes when the re-vote option is enabled.
- Remembering voters via IP, cookies, or WordPress profiles. Optionally, vote history can be cleared.
- Embedding polls in posts with the
[democracy]
shortcode. A visual editor button is available for ease of use. - Providing a widget (optional).
- Streamlined poll management through the WordPress toolbar (optional).
- Flexibility to disable or embed CSS/JS files into the HTML.
- Adding notes under polls for additional context.
- Customizing poll designs with CSS themes.
Multisite support is available starting from version 5.2.4.
Requires PHP 5.3 or later.
Usage
Usage (Widget)
- Go to
WP-Admin -> Appearance -> Widgets
and select theDemocracy Poll
widget. - Add the widget to an available sidebar.
- Configure the widget settings and save.
- Done!
Usage (Without Widget)
- Open the
sidebar.php
file of your theme:wp-content/themes/<YOUR THEME NAME>/sidebar.php
. -
Insert the following code where you want the poll to appear:
php
<li>
<h2>Polls</h2>
<ul>
<li><?php democracy_poll();?></li>
</ul>
</li>
- To display a specific poll, use
<?php democracy_poll( 3 ); ?>
, where 3 is your poll ID. - To embed a specific poll in a post, use
[democracy id="2"]
, where 2 is your poll ID. - To embed a random poll in a post, use
[democracy]
.
Display Archive
To display the polls archive, use the function:
php
<?php democracy_archives( $hide_active, $before_title, $after_title ); ?>