Pause plugin option page until all data manipulation is complete

You can only do this by “loading content into all the posts in the blog” asynchronously (in the background). So, move the processing inside a function that you hook on wp_ajax_your_action_tag. Then call this function with javascript by requesting WP to fire “your_action_tag”. There’s a example on the linked page… If you want to display … Read more

paginate posts on admin page

This is what ended up solving it (I’ll include the relevant parts) $total = wp_count_posts()->publish; $perpage = 10; $curpage = isset( $_GET[‘pagenum’] ) ? intval($_GET[‘pagenum’]) : 1; global $post; $args = array( ‘post_type’ => ‘post’, ‘post_status’ => ‘publish’, ‘order’ => ‘DESC’, ‘orderby’ => ‘date’, ‘posts_per_page’ => $perpage, ‘offset’ => $perpage*($curpage-1) ); $pages = ceil($total/$perpage); $dash_posts … Read more

How to change a specific admin label

You could try that with the gettext filter in the following manner. function rename_header_to_logo( $translated, $original, $domain ) { $strings = array( ‘Header’ => ‘Logo’, ‘Custom Header’ => ‘Custom Logo’, ‘You can upload a custom header image to be shown at the top of your site instead of the default one. On the next screen … Read more

Custom page in plugin visible in menu

I found the answer on WordPress Forum: http://wordpress.org/support/topic/add-backend-page-without-menu-item#post-2135050 It requires add_submenu_page() with slug = null (first argument). In WordPress documentation it’s marked as ‘required’ so it looks like it’s required but can be null.

adding page types in menu

Sorry, try this: ‘show_ui’ => false, ‘menu_position’ => ‘edit.php?post_type=main_posttype or registered section’ For example if you want it under Themes it would be: ‘menu_position’ => ‘themes.php’ This on your post type registering.

Admin sidebar customization

This may sound silly but are you sure you have administrator permissions? (Logged in with an account with Administrator privileges.) If you are sure you have the correct permissions, you may also want to check with the original theme developer to see if there are white label admin features enabled within the theme. You will … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)