Validation of date field - same as another date field within a group

Support Meta Box AIO Validation of date field - same as another date field within a group

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #46411
    FredrikFredrik
    Participant

    How can I make a date field in a Custom Post validate so that it is required to be equal to another date field that's within a group? What do I type into the field value box for the grouped date picker?

    #46424
    PeterPeter
    Moderator

    Hello Fredrik,

    With PHP code, you can use the filter hook rwmb_after_save_field to validate the field value.
    https://docs.metabox.io/actions/rwmb-after-save-field/

    With Javascript code, you need to create a custom code to check the two field values. Meta Box only supports validating for a single field with code. Refer documentation
    https://docs.metabox.io/validation/

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.