I know that using an underscore in front of a custom field name hides it from display on the front-end, e.g. _custom_field_name
. In my experience, WordPress also prevents one from adding such a custom field on the front end.
Before I go spelunking around core, I wanted to ask: Is there an “easy” way to allow _custom_fields
to be added from wp-admin/post.php?
The reason is this: we rely on hidden custom fields, but when troubleshooting production issues in prod it would be useful to be able to inject certain hidden post meta. I’m not a fan of touching the production database by hand.