Unschedule a post
To revert from scheduled to draft without publishing immediately this works for me (WordPress 3.9.1 ) change scheduled date to yesterday OK Save as draft done
To revert from scheduled to draft without publishing immediately this works for me (WordPress 3.9.1 ) change scheduled date to yesterday OK Save as draft done
add_filter(“manage_{xxxx-xxx}_columns”, “cusotm_callback_fun02” ); is used to add the column itself to the list of columns for that post_type. add_action(“manage_posts_custom_column”, “custom_callback_fun01”); adds the actual content of the column per post.
Taking a look at the register_post_type() function in WordPress source, it appears that WordPress uses isset() to check the feeds arg instead of empty(), meaning that a false value will return true. To fix this, you might try setting ‘feeds’ => null and then flush your rewrite rules from Settings > Permalinks (remember to do … Read more
function exclude_single_posts_home($query) { if ($query->is_home() && $query->is_main_query() && !is_admin()) { $query->set(‘post__not_in’, array(post-id)); } } add_action(‘pre_get_posts’, ‘exclude_single_posts_home’); Source: pre_get_posts
HTML language includes a special tag for displaying inline code. To apply it to your text, switch to the ‘Text’ visual editor tab and place the <code> tag before your bit of code, and the </code> tag afterwards. If you want to use the backtick ` character for highlighting code like you do on Stack … Read more
No. echo do_shortcode() is a function call. You can not pass a conditional statement as an argument of a function. What you need to do is pass in the returned result of your query as an argument of the function; //assuming you have taken care of your query prior to this point if ( have_posts() … Read more
I would do this with $query->current_post and $query->post_count with $query = new WP_Query(args);. With this you may get the position and the total of posts.
User ‘restrict_manage_posts’ filter to add another filter. Use the following code in functions.php function kc_add_taxonomy_filters() { global $typenow; // an array of all the taxonomyies you want to display. Use the taxonomy name or slug $my_taxonomies = array( ‘post_tag’ ); switch($typenow){ case ‘post’: foreach ($my_taxonomies as $tax_slug) { $tax_obj = get_taxonomy($tax_slug); $tax_name = $tax_obj->labels->name; $terms … Read more
In the post edit page, just under the ‘Publish’ button, add a button, ‘Reject and Notify’ that once clicked open a modal (thickbox) window that contain a form (pre-compiled with the post author name, post title and a standard message) that you can use to send the email to post author. To accomplish this you … Read more
Problem is that meta values are not unique key/value data. E.g. with the key ‘OneKey’ you can have a lot of values for the same post. So, in a flat table, for the column ‘OneKey’ you should have multiple rows where the post id is the same and seems to me is not what you … Read more