[WordPress] 外掛分享: HP Comment Form Validation

首頁外掛目錄 › HP Comment Form Validation
WordPress 外掛 HP Comment Form Validation 的封面圖片
10+
安裝啟用
尚無評分
7 天前
最後更新
問題解決
WordPress 6.5+ PHP 8.0+ v2.0.0 上架:2021-09-27

內容簡介

HP Comment Form Validation 為 WordPress 原生留言表單增添輕量且友好的驗證功能,改善留言提交體驗,並在無效欄位旁顯示清晰的驗證訊息,讓使用者更容易理解。

【主要功能】
• 驗證留言欄位
• 驗證必填的作者名稱
• 驗證必填的電子郵件地址
• 驗證電子郵件格式
• 驗證可選的網站網址
• 支援原生 WordPress 留言表單

外掛標籤

開發者團隊

⬇ 下載最新版 (v2.0.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「HP Comment Form Validation」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

HP Comment Form Validation adds lightweight, user-friendly validation to the native WordPress comment form.
It improves the comment submission experience by showing clear validation messages directly next to invalid fields while keeping WordPress Core responsible for the actual comment workflow.
The plugin is intentionally simple and lightweight.
There are no settings pages, database tables, external APIs, subscriptions, advertisements, or tracking.
Features

Validates the comment field.
Validates required author name.
Validates required email address.
Validates email address format.
Validates optional website URLs.
Respects the WordPress “Comment author must fill out name and email” setting.
Works for logged-in and logged-out users.
Supports native WordPress comment forms.
Provides accessible validation feedback.
Focuses the first invalid field after submission.
Adds ARIA validation attributes for assistive technologies.
Includes server-side validation.
Works without jQuery.
Loads frontend assets only where comments are available.
Does not create database tables.
Does not store plugin settings.
Does not collect analytics.
Does not connect to external services.
Does not display subscription or upgrade notices.
Translation ready.
Lightweight and developer friendly.

How It Works
After activation, the plugin automatically enhances the standard WordPress comment form.
No configuration is required.
When a visitor submits an invalid comment form, HP Comment Form Validation displays an appropriate validation message next to the affected field.
The plugin respects your existing WordPress Discussion settings.
For example, when:
“Comment author must fill out name and email”
is enabled under Settings > Discussion, the plugin requires those fields for logged-out visitors.
When the setting is disabled, name and email remain optional.
Logged-in users are validated according to the fields WordPress displays to them.
Validation Layers
HP Comment Form Validation uses multiple validation layers:
1. Accessible frontend JavaScript validation for immediate feedback.
2. Server-side PHP validation when comments are submitted.
3. The standard WordPress Core comment processing system.
JavaScript is used only to improve the user experience.
Server-side validation remains available even if frontend JavaScript is disabled or bypassed.
Lightweight by Design
HP Comment Form Validation does not attempt to replace the WordPress comment system.
It does not:
* Create custom comment tables.
* Replace wp-comments-post.php.
* Create unnecessary WordPress options.
* Add an admin dashboard.
* Load a JavaScript framework.
* Require jQuery.
* Connect to a SaaS service.
* Require registration or an account.
* Add advertisements.
* Track visitors or administrators.
The goal is simple: improve native WordPress comment validation while keeping the plugin small and maintainable.
Privacy
HP Comment Form Validation does not collect, store, transmit, or process additional personal data of its own.
The plugin validates fields already provided by the native WordPress comment system, such as:
* Name
* Email address
* Website URL
* Comment content
Storage and processing of submitted comments remain handled by WordPress Core and your website’s existing configuration.
The plugin:
* Does not use tracking cookies.
* Does not collect analytics.
* Does not contact third-party services.
* Does not create its own database records.
* Does not transmit visitor data externally.
Site owners remain responsible for providing an appropriate privacy policy for the WordPress comment system and any other services used on their website.
Accessibility
The plugin is designed to provide accessible validation feedback.
Validation includes:
* aria-invalid for invalid form controls.
* aria-describedby associations between fields and validation messages.
* Accessible validation messages.
* Keyboard-compatible form submission.
* Focus management for the first invalid field.
* Theme-friendly validation markup.
Accessibility will continue to be reviewed as the plugin evolves.
Compatibility
HP Comment Form Validation is designed for the native WordPress comment form generated through standard WordPress APIs.
It should work with most properly developed WordPress themes that use the standard comment form structure.
Themes or plugins that completely replace the WordPress comment form or comment submission process may require additional compatibility work.
If you discover a compatibility issue, please report it through the WordPress.org support forum.

延伸相關外掛

文章
Filter
Mastodon