Home › Forums › Backend Issues (wp-admin) › Permalink ACF Field › Reply To: Permalink ACF Field
I believe you need to set the value option too. Maybe something like this:
$args = array( 'meta_query' => array( 'relation' => 'OR', array( 'key' => 'url_field_past', 'compare' => '!=', 'value' => '' ) ) ); $query = new WP_Query( $args );
If that doesn’t work, could you please try the following code instead?
$args = array( 'meta_query' => array( 'relation' => 'OR', array( 'key' => 'url_field_past', 'compare' => 'NOT EXISTS', ) ) ); $query = new WP_Query( $args );
I hope this helps 🙂
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
Accordions are a great way to group related information while allowing users to interactively show and hide content. In this video, Damon Cook goes in-depth on how to create an accessible accordion block using ACF PRO’s Repeater field.https://t.co/RXT0g25akN— Advanced Custom Fields (@wp_acf) March 2, 2023
© 2023 Advanced Custom Fields.