filter using custom fields
filter using custom fields
filter using custom fields
Adding specific custom fields (images) to post excerpt
How are you printing the contents of the ACF field in your site code? Assuming that you have self-coded theme files, instead of using the_field() to print the field content, you should echo get_field() passed through the ‘the_content’ filter, eg: echo apply_filters( ‘the_content’, get_field( ‘my_field_name’ ) ); and it will apply the modifications from your … Read more
Such a dummy! Turns out that since I was wp_enqueque for the JS script with the footer. I had commented out get_footer(); in my single.php page and as a result was not loading.
ACF Pro Date Picker not coming through on Loop
Hope this code may be help you <?php /* * Add columns to event post list */ function add_acf_columns ( $columns ) { return array_merge ( $columns, array ( ‘event_date’ => __ ( ‘Event Date’ ), )); } add_filter ( ‘manage_events_posts_columns’, ‘add_acf_columns’ ); /* * Add columns to event event list */ function events_custom_column ( … Read more
The problem is that you use wrong ACF function. get_field_object returns the settings of a specific field. Each field contains many settings such as a label, name and type. This function can be used to load these settings as an array along with the field’s value. So get_field_object(‘icon’)[‘ID’]) doesn’t return the ID of image attachment, … Read more
OK, I realized I should just add every default WP key it to the $ignore array, like this, I added ‘page’: $ignore = array(‘page’, ‘per_page’, ‘search’, ‘order’, ‘orderby’, ‘slug’);
How to display custom post type pagination buttons when processing AJAX request
OK, I solved in this way: ‘meta_query’ => array( array( ‘key’ => ‘product’, ‘value’ => ‘”‘.get_the_id().'”‘, ‘compare’ => ‘LIKE’ ) )