Filter In Reply comments from WordPress Admin Panel

In your comments loop, skip the children: if( !empty( $comment->comment_parent ) ) { //if the comment has a parent, skip it as it’s not level 1 continue; } Edit: Above example would only help in the reading loop, below example should help in admin area: add_filter(‘the_comments’, ‘top_level_comments_filter’); function top_level_comments_filter($comments){ global $pagenow; if($pagenow == ‘edit-comments.php’){ foreach($comments … Read more

My WordPress Admin looks messed up when I edit posts or pages

Ultimate TinyMCE adds extra toolbar buttons to your post content editor. On your screenshot, these extra buttons are extending over into the right sidebar column. If you want to continue to run Ultimate TinyMCE and have these extra toolbar buttons, you have two options: At the top of the Edit Post screen, go to Screen … Read more

Adding html format on tinymce visual editor

I Googled wordpress mce filter, and it led me pretty directly to a TinyMCE Custom Styles tutorial on the Codex. It’s not a simple thing — you have to, for starters, enable a hidden button in TinyMCE called styleselect — but it looks like the tutorial is fairly complete. Is that what you’re looking for? … Read more

Plugin: AJAX query external API to sync to tables

Sketch/Concept To make requests to remote/external APIs, use the WP HTTP API. More in depth examples/details can be found in some of my answers here. Then simply add an admin page with add_submenu_page() or add_menu_page() or the related functions. Finally add a script via wp_register/enqueue_script() on the admin_enqueue_scripts-hook. There you fire an ajax (search archives) … Read more

All Users > User List > Update User Meta Field Inline

Yes, we need jQuery for that. The first thing is to give proper classes and ID’s to the elements. In manage_users_custom_column, add a class and a data selector to the checkbox: “<input type=”checkbox” data-approval=”#approval-$user_id” class=”my-class” value=”{$column_value}” />” And in user_row_actions, an ID to the <a> tag: id=’approval-$user_id’. Now, we have all the elements properties and … Read more