Automattic / Automattic/jetpack
Contact Form: Support custom field validation by themes/plugins
- Dominant language
- PHP
- Stars
- 1.8k
- Forks
- 898
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 774
Description
#### Steps to reproduce the issue
The `validate()` function of `Grunion_Contact_Form_Field` has no filters so it isn't easy to write custom validation logic for a field - for example adding your own validation for a url or making the email validation stricker/looser
#### What I expected
A filer
#### What happened instead
There was no filter
Contributor guide
Research direction
Start by locating the Grunion_Contact_Form_Field class and its validate() function in the Jetpack codebase. Review nearby validation behavior and existing filter patterns, then determine how a filter can support custom URL or email validation. Done means themes and plugins can alter field validation without modifying the class.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php, wordpress
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100