Comments do not respect display_name setting, how to make plugin to overcome this

This code does the job with a filter. Doesn’t care what the comment says the author’s name is. Nothing particularly tricky about it. Should be self-explanatory. add_filter(‘get_comment_author’, ‘wpse31694_comment_author_display_name’); function wpse31694_comment_author_display_name($author) { global $comment; if (!empty($comment->user_id)){ $user=get_userdata($comment->user_id); $author=$user->display_name; } return $author; }

Widget translation on my plugin

Based on your comment: The html generated by the widget? That one just shows the Strings in the _e function for eg: _e(“Category”) displays “Category” I suspect that you’ve not configured your translation strings properly. You need to include the textdomain in every translation string function call, or else the strings will never get translated. … Read more

How to write a plugin to add users to a mail list

You would hook into profile_update and user_register. First check to see if it’s a new user and whether she is an admin/editor. Then send the mail. Same story with updating the user: see if the role has changed, and whether the new role is admin or editor. <?php add_action( ‘profile_update’, ‘wpse33949_profile_update’ ); add_action( ‘user_register’, ‘wpse33949_profile_update’ … Read more

WordPress mode for emacs?

WordPress coding standards are loosely based on the Pear Coding Standards The Drupal open source project also follows similar standards and has published a guide to configuring various editors and IDEs which includes code for a Emacs Drupal mode which can be modified slightly for WordPress.

Communicate between plugins

your question depends a lot on what you want to do .. But in general , when a plugin is loaded or executed, the functions are being “registered” in PHP server and are available for all to use (depending of course HOW you write them) … So for example, to detect if a plugin is … Read more

Sending WP posts to external API

I think the better way to handle it would be to have the other site scrape the feed for the content. Alternately, you could call an API on the receiving server with every execution of the publish_posts hook, but this would leave you with the issue of not being able to concurrently edit. Another solution … Read more