Lecteur Markdown
POLLS_DOCUMENTATION_EN
Feature: Polls #
Opinion polling system with multilingual support, vote tracking by IP address, results displayed as progress bars and archiving of past polls.
---
Installation and Configuration #
Via FTP: Upload the `polls/` directory into `/plugins/`.
Via package manager: Select `polls` from the available plugins list.
Paths:
- Main plugin: `/plugins/polls/polls.php`
- Configuration: `/plugins/polls/conf/polls.conf.inc.php`
- Locales: `/plugins/polls/locale/`
Configuration parameters (`polls.conf.inc.php`):
| Variable | Default | Description |
|---|---|---|
| `$basedatadisplay` | `'yes'` | Display in management interface |
| `$basedisplevel` | `BASE_LEVEL_MODERATOR` | Level to create/manage polls |
Required SQL tables: `poll`, `poll_setup`, `poll_reference_i18n`
---
Usage #
Public Browsing #
- Active poll displayed with its answer options
- One vote per IP address (database check)
- Real-time results with percentages and progress bars
- Link to previous polls
Administration (moderator) #
- Create a poll with translations (i18n) for each option
- Designate the active poll
- View and manage archived polls
Exposed utility functions:
- `polls_getAvailableLanguages()` — available languages
- `polls_getCurrentLanguage()` — current language
- `polls_getI18n(int $poll_id, string $lang)` — poll translation
---
Hooks and Entry Points #
?obj=polls.php — Active poll
?obj=polls.php&vote=OPTION_ID — Vote (GET)
?obj=polls.php&results=1 — Results
?obj=polls.php&previous=1 — Previous polls
---
Dependencies #
- `Beamreactor\Database\SQL`
- `Beamreactor\Sanitizer\Parser`