WP_Query – How To Query Only Custom Posts With No Children of Their Own?
WP_Query – How To Query Only Custom Posts With No Children of Their Own?
WP_Query – How To Query Only Custom Posts With No Children of Their Own?
I managed to get it working. This is the code i used: <?php echo get_the_term_list( $post->ID, ‘regisseur’, ‘Regisseur: ‘, ‘, ‘, ” ); ?> All custom taxonomies show fine now. Only thing i need now is to not show a blank line when a custom taxonomy has no values. If anybody has any ideas?
Thanks to the help of @JacobPeattie the problem was how the data was being saved. So instead of: if(isset($_POST[‘assign-classes’])) { update_post_meta( $post->ID, ‘assign-classes’, $_POST[‘assign-classes’] ); } It is now: delete_post_meta($post->ID, “assign-classes”); for($i = 0; $i < count($_POST[‘assign-classes-all’]); $i++){ add_post_meta( $post->ID, ‘assign-classes’, $_POST[‘assign-classes-all’][$i], false ); } Only thing that was weird is that at first I … Read more
The taxonomy is using the same slug as your custom post type. Try to rewrite the custom taxonomy or custom post type slug with different names if possible or try the solution suggested here: Add category base to url in custom post type/taxonomy
Given that there is a custom post type in the code. And what you may want to do includes a few steps and tests. The following may help in kicking start and continue to explore. The best things to do is always testing in a fundamental environment without plugins and theme interference by using the … Read more
WordPress Page hierarchy ( parent is singular of custom post types slug ) is returning not found
I’m not sure about the sort of precise figures a performance/algorithm researcher would be looking for. However, in terms of actual performance there is no difference. The WP database can take a beating and I’ve done plugins with dozens and dozens of filters and hooks and queries and they still run very very fast. Furthermore, … Read more
Have you set WP_DEBUG and WP_DEBUG_LOG to true in your wp-config.php? Doing so makes debugging a lot easier as you’ll get an error_log in your wp-content directory, which will tell you what is it it your code that is causing the error. If I had to make a guess, I’d say it’s the $post->id that … Read more
custom post types, custom fields and normalization
wordpress get menu id by custom post_type?