I would like to use a user field to control whether or not a user can edit a post.
I have a user field called: allowed_users.
The logic: if the id of the current user is in the array of allowed users than let the user edit the post.
Does anyone know if this is possible?
I can’t find any specific information on this https://www.google.com/search?q=wordpress+select+what+users+can+edit+a+post
But there are a few examples of limiting users to specific posts in those results and there is a plugin the can limit users based on categories https://wordpress.org/plugins/author-category/
I would say that it’s possible, but I can’t say how you’d accomplish it. If it were me I’d start by downloading the plugin I linked to and then dig through the code to see how they limit users to categories and then figure out how to do the same thing based on a field on the post. Probably many hours of work involved here.
Thanks, I’ll try the plugin.