Get User Post if Private
Get User Post if Private
Get User Post if Private
What type of index should I use for postmeta?
ACF (Advanced Custom Fields) not updating post or postmeta values
The server cache of WP engine can bother a little, they have a very invasive cache. Try removing the cache from the server: https://wpengine.com/support/cache/ For debugging you could print the result of update_post_meta ($ post_id, $ field, $ _POST [$ field]); (which will be true or false) Because get_post_meta sometimes does not work since In … Read more
Custom Field Values not updating unless I click “Update” twice
This happens due to the nature of ajax calls – they are asynchronous. When you have a lengthy function (or heavy plugins and slow site loading), several ajax calls are running at the same time, and nobody can predict, which one will get access to db data faster. Usage of own tables is not a … Read more
How can I filter posts when the meta_value is a serialize object?
Querying by postmeta is very inefficient, so for a site with many posts, you’re likely to run into issues. In this type of situation you’re almost always better off creating custom taxonomies. Taxonomy queries are much less demanding and scale better on larger sites.
How to hide meta block(s) in certain post format
One way of doing it would be to modify your current code and add the links in there: function category_name_shortcode() { global $post; $post_id = $post->ID; $catName = “”; foreach((get_the_category($post_id)) as $category){ $catName .= ‘<a href=”‘ . get_term_link($category) . ‘”>’ . $category->name . ‘</a>, ‘; } return $catName; } add_shortcode( ‘post_category’, ‘category_name_shortcode’ ); But there’s … Read more