Automattic / Automattic/jetpack

Forms: Save the timestamp for date based input fields

Open
#41,525 4 comments 0 reactions 0 assignees View on GitHub
[Block] Form [Feature] Forms [Plugin] Jetpack [Pri] Normal [Status] Auto-allocated Bug Triaged
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

### Impacted plugin

Jetpack

### Quick summary

Currently when a user fills our the form with the date field. We only store the value that the user submitted through the form but it would be good to also store a timestamp so that we can display the input in any format down the line.

Since the user can change the form's formatting the value of the data could become not usable. Since we don't track how the form changes and which version of the form was submitted.

See: It is not possible to tell if the user entered "mm/dd/yyyy" or "dd/mm/yyyy"
![Image](https://github.com/user-attachments/assets/e00f9177-d4a7-45a1-93b0-28777dab395b)

### Steps to reproduce

1. Create a form with the date input field.
2. Fill out the form.
3. Change the forms date input fields formatting.
4. Notice when we display the value that the use submitted but not the intended value.

### Site owner impact

Fewer than 20% of the total website/platform users

### Severity

Moderate

### What other impact(s) does this issue have?

Individual site owner revenue

### If a workaround is available, please outline it here.

_No response_

### Platform (Simple and/or Atomic)

_No response_

Contributor guide

Open the contributing guide

Research direction

Start by tracing Jetpack's date-field submission and storage path, then review how submitted values are displayed after a form's date formatting changes. Done means date submissions retain a timestamp alongside the submitted value so later display can distinguish formats such as mm/dd/yyyy and dd/mm/yyyy.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.