Support

Account

Home Forums General Issues Using checkbox fields in custom queries Reply To: Using checkbox fields in custom queries

  • Are you using a checkbox field or a true/false field.

    Checkboxes are stored as serialized data and you’re not going to be able to use WP_Query to filter by a checkbox field.

    If you use a true/false field then you can use WP_Query, the values of a true/false field are 0 (zero) for false and 1 for true.

    the last code example you have should work for a true/false field if use substitute 0 & 1 where you have true and false.