Support

Account

Home Forums General Issues If get_fields is empty not working Reply To: If get_fields is empty not working

  • Yeah ! It’s working well with both code 🙂
    The only problem is here
    $value = get_field(‘date_de_debut’);

    I think that $value is always empty.

    An other example if I use this:

    $value = get_field('date_de_debut');
    if (empty($value)) {
    $query_array[‘meta_key’] = ‘date_de_debut’;
    $query_array[‘orderby’] = ‘meta_value’;$
    }

    The order change and works well according to the meta_key ‘date_de_debut’