The 0th of July
|Reported by:||tellyworth||Owned by:||anonymous|
It's possible to enter a post date with a zero on the write post page. WP doesn't validate the date, and unless MySQL is running in strict mode the invalid date will get stored in the post_date column.
Steps to reproduce:
- New Post
- Edit the timestamp
- Change the day field to "00"
- Click the View Post link
Expected: WP should validate the date and change it to something that works.
Actual: the post is published but the permalink is 404 because of a quirk in the way get_permalink() handles the post_date field.
The steps to reproduce assume MySQL is not running in strict mode, I haven't tested that case. Reproduced in trunk, it probably affects all versions.