I’m loading custom post type to different pages by changing cat id and sometimes post type name query_posts(array( 'post_type' => 'posttype_name','posts_per_page'=>-1, 'tax_query' => array( array( 'taxonomy' => 'type', 'terms'...
I’m using the ACF plugin to create custom fields which get applied to a custom post type (projects). In my functions.php file I am trying to use pre_get_posts to...
I’ve a custom post type with some custom meta box. I want to filter my custom post type posts using custom meta value. I’ve written the code below. But...
I current have a custom field that is displaying even if there is not data inputted in the meta box when posting. How do I remove the hr, title,...
i have a multiple meta (custom field) in posts as “cd_meta” that it (cd_meta) have a meta as “artist”, also “artist” meta maybe have one or more value in...
I’m trying to display custom post types with custom date field value being before today. It works OK for showing posts before today, but the order is only based...
With the cmb2 plugin I created a metabox with a textarea metafield this way: function myprefix_register_metabox() { $prefix = 'myprefix_'; $cmb = new_cmb2_box( array( 'id' => $prefix . 'metabox',...
I have a custom meta box for saving values from two input fields into a single post meta field. The data is saved serialized in the DB: get_post_meta( $post->ID,...
I have a custom post type where there is an option to sort by date. There is however a custom date field that allows changing the display date. This...
Good morning! Is there any way to do searches with the WordPress REST API with custom fields, being more specific, I have some custom posts, with a custom field...