Support

Account

Home Forums Backend Issues (wp-admin) Validate one field against another Reply To: Validate one field against another

  • Not realy.. I need to compare value if it exists in othere posts and if does then fail the validation, but since we don’t have $post_id i can’t exclude current post to check how many posts there are with meta_value. And if i don’t exclude curent id then when i do validation on new post it doesn’t have a meta_value set and get_posts finds only 1 post and validation is ok, so after validate_value i have 2 pots with same meta_value

    So if someone knows how can we get post_id in validate_value please tell us!