=== Deconde Virtuelles Schwarzes Brett ===
Contributors: deconde
Donate link: https://ko-fi.com/deconde
Tags: notice board, bulletin board, community, post-it, photos
Requires at least: 5.8
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 3.10.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Virtual notice board with post-it notes, optional photo upload, and an approval workflow run by an administrator.

== Description ==

Virtuelles Schwarzes Brett adds a digital pinboard to your website where visitors and logged-in users can leave short messages as colourful post-it notes — for example for club, neighbourhood, or community websites.

New messages are not publicly visible at first ("pending") and only appear on the board once an administrator has approved them in the backend. Posts can automatically disappear from the public board again after a configurable display duration.

= Key Features =

* Shortcode `[schwarzes_brett]` – the board can be embedded on any page or post.
* Form with required fields first name, last name, message (max. 280 characters).
* A way to get in touch is required: email OR phone number, shown on the post-it as a clickable `mailto:`/`tel:` link.
* Optional photo upload (JPG, PNG, GIF, WEBP), maximum file size configurable in the backend.
* Approval workflow: new posts only become publicly visible after admin approval.
* Automatic expiry: admin-configurable display duration per post (0 = unlimited).
* Random pastel colour (8 shades) and a slight tilt per note for an authentic pinboard look.
* AJAX form, no page reload required.
* No WordPress user account needed to submit a message.
* Fully translation-ready (text domain `deconde-virtuelles-schwarzes-brett`); translations are provided via translate.wordpress.org.

= Pro Version =

There is a separate add-on plugin, [Virtuelles Schwarzes Brett Pro](https://deconde.de/schwarzes-brett-pro/), that requires this free plugin and adds features such as multiple boards, categories, automatic moderation, pinned and expiring notes, email notifications, CSV export and custom colour palettes. This free version is complete and fully functional on its own; it contains no locked features, license checks or trial code.

= Data Security =

* All form input is validated and sanitized server-side; all output is escaped appropriately for its context.
* Every form-processing action (submitting a message, deleting a message, approving/rejecting, saving settings) is protected against CSRF with WordPress nonces.
* Database access is exclusively done through parameterized queries (`$wpdb->prepare()`).
* Photo uploads are validated against their actual file content (`wp_check_filetype_and_ext()`), not just the file extension.
* Approving, rejecting, removing, and all settings are restricted to users with the `manage_options` capability (typically administrators).

== Installation ==
1. Upload the plugin folder to the `/wp-content/plugins/` directory.
2. Activate the plugin through the 'Plugins' menu in WordPress.
3. Place the `[schwarzes_brett]` shortcode on any page, e.g. `[schwarzes_brett titel="Our Team Board"]`.
4. Under "Schwarzes Brett → Settings", adjust the display duration and maximum photo size as needed.

== Frequently Asked Questions ==

= Do I need to register to post a message? =

No. Submitting a message does not require a WordPress user account.

= Are new messages published immediately? =

No. Every new message is "pending" at first and only appears on the public board once an administrator has approved it under "Schwarzes Brett → Moderation".

= What happens once the display duration expires? =

The post automatically disappears from the public board but stays visible in the backend under "Published messages" for reference, until it is manually removed. With a display duration of 0, posts remain visible indefinitely.

= Can I customize the colour palette or the character limit? =

The colour palette can be customized via the `dvsb_color_palette` filter, and the appearance via `assets/style.css`. The message character limit (default 280 characters) can be changed in the form (`maxlength`) as well as server-side in `dvsb_ajax_add_note()`.

= Is the plugin ready for other languages? =

Yes. All text runs through the text domain `deconde-virtuelles-schwarzes-brett`, and WordPress loads the matching translation automatically for you. Translations are provided through [translate.wordpress.org](https://translate.wordpress.org/); anyone can contribute or improve a translation there.

== Screenshots ==

1. The public board with approved post-it messages.
2. Form for submitting a new message.
3. Moderation view in the backend.

== Changelog ==

= 3.10.0 =
* New: neutral developer hooks (filters/actions) for add-on plugins — extra form fields, submission validation and status, note classes and header, moderation table columns, and a cleanup action on deletion. Without an add-on, behaviour is unchanged and every message still goes through manual approval.
* Changed: the board query now lives in the function `dvsb_query_visible_notes()`.

= 3.9.1 =
* Changed: the "Provided by deconde" credit under the board is now optional and disabled by default (Settings → "Credit" checkbox), per WordPress.org guidelines.

= 3.9.0 =
* Changed: removed dormant Pro-only code paths (multi-board, categories, automatic moderation, branding toggle) from the free plugin per the WordPress.org directory guidelines — these live exclusively in the separate Pro plugin now. The free version's own functionality is unchanged.
* Changed: all internal function, option, and hook names now use the `dvsb_` prefix (was `vsb_`) to avoid collisions with other plugins.
* Changed: removed `load_plugin_textdomain()` — not needed for WordPress.org-hosted plugins since WordPress 4.6.
* Changed: removed the bundled `.po`/`.mo` translation files; translations are now provided via translate.wordpress.org.
* Fixed: the admin menu icon size is now set via `wp_add_inline_style()` instead of a directly printed `<style>` tag.

= 3.8.0 =
* Changed: plugin renamed to "Deconde Virtuelles Schwarzes Brett" and the text domain updated to `deconde-virtuelles-schwarzes-brett` (per WordPress.org plugin directory naming guidelines – the previous name was too generic). No functional changes.

= 3.7.2 =
* Added: donate link (Ko-fi) in readme.txt.

= 3.7.1 =
* Changed: the credit line under the board now reads "Provided by deconde" instead of "Powered by Virtuelles Schwarzes Brett" (still links to deconde.de, now with a fitting provider name as link text).

= 3.7.0 =
* New: complete French and Spanish translation (fr_FR, es_ES) for all frontend and backend text.

= 3.6.0 =
* New: complete English translation (en_US and en_GB) for all frontend and backend text.

= 3.5.1 =
* Fix: the backend menu icon was barely visible on the default admin colour scheme (dark icon on a dark menu bar) and rendered oversized in places.

= 3.5.0 =
* New: further extension points for the Pro add-on – automatic moderation (rejection/auto-approval before saving). Without Pro, behaviour is unchanged; every message still goes through manual approval.

= 3.4.0 =
* New: further extension points for the Pro add-on – custom colour palettes, categories/tags, and CSV export. Without Pro, behaviour is unchanged.
* Database table extended with a category column (preparation for Pro).

= 3.3.0 =
* New: defined extension points (filters/actions) for the optional Pro add-on – without Pro, behaviour is unchanged.
* Database table prepared for the multi-board feature (Pro).

= 3.2.0 =
* Security improvement: photo uploads are additionally validated against their actual file content (not just the file extension).
* More robust error handling for failed or oversized photo uploads.
* Custom menu icon in the WordPress backend.
* Preparation for release on the WordPress.org plugin directory (readme.txt, language files, uninstall routine).

= 3.0.0 =
* New: optional photo upload for messages (JPG, PNG, GIF, WEBP), shown on the post-it.
* New: admin-configurable display duration – approved posts automatically disappear from the public board once it expires.

= 2.0.0 =
* New: approval workflow – new messages must be approved by an administrator before appearing on the board.
* Contact info (email or phone number) is a required field from this version on.

= 1.0.0 =
* First version of the plugin: virtual notice board with post-it notes in 8 pastel colours, form with required fields first name, last name, and message, plus optional contact info.

== Upgrade Notice ==

= 3.10.0 =
Adds developer hooks for add-on plugins. No changes to the plugin's own behaviour; no special steps required.

= 3.9.1 =
The credit link under the board is now off by default; re-enable it under Schwarzes Brett → Settings if you like.

= 3.9.0 =
Internal function/option/hook names changed prefix from `vsb_` to `dvsb_`, and bundled translation files were removed in favour of translate.wordpress.org. No changes to the plugin's own features; a Pro add-on built against the old `vsb_` hooks would need to be updated.

= 3.8.0 =
Plugin renamed to "Deconde Virtuelles Schwarzes Brett" (text domain changed accordingly). No functional changes, no action required.

= 3.7.1 =
Changes the provider credit under the board to "Provided by deconde". No special steps required for this update.

= 3.7.0 =
Adds complete French and Spanish translations. No special steps required for this update.

= 3.6.0 =
Adds a complete English translation. No special steps required for this update.

= 3.5.1 =
Fixes the backend menu icon display (visibility and size). Update recommended.

= 3.5.0 =
Adds an internal extension point for automatic moderation in the optional Pro add-on. No special steps required for this update.

= 3.4.0 =
Adds further internal extension points for the optional Pro add-on (colour palettes, categories, CSV export). No special steps required for this update.

= 3.3.0 =
Adds internal extension points for the optional Pro add-on. No special steps required for this update.

= 3.2.0 =
First release on the WordPress.org plugin directory. No special steps required for this update.
