Ready to get started?Download WordPress

Plugin Directory


Hikari Enhanced Comments


Is "Hikari Enhanced Recent Comments" widget related to WordPress core "Recent Comments"?

Well, in parts. PHP code is totally independant, but based on it. But it uses compatible CSS classes, so it shoud fit to theme layouts.

Can I use both core "Recent Comments" and "Hikari Enhanced Recent Comments" widgets together?

Sure! You can use them together and as many times as you want!

Is your titled comments plugin required to use the widget?

No, my idea isn't to force somebody to use them together.

Indeed, Hikari Enhanced Comments was first idealized to be part of Hikari Titled Comments, being implemented on a future version. But when I started coding it, I saw that core "Recent Comments" couldn't be simply extended (I did that :P ), and using filter wasn't enough for me. Code was becoming too big and getting out of "titled comments" scope, and also there was ip2nation to be installed separated, so I decided to port these features to a separated plugin and make both compatible.

If both are available they work together, but they work alone pretty fine too.

Your titled comments plugin requires WP 2.9, and this enhanced comments requires 2.8, strange!

All my plugins require PHP5 because I use OOP, and WP 2.8 because I use settings_fields().

Hikari Titled Comments requires WP 2.9 only because it uses comments metadata. Even though Hikari Enhanced Comments supports Hikari Titled Comments, it only uses its functions, it doesn't go over comments metadata directly, and since Hikari Enhanced Comments doesn't use metadata code, it works with WP 2.8. Remember these plugins work together but they don't require each other to do their own job :)

I've looked on HTML code your widgets generate, and noted they use ordered lists, but ERC shows no list marking and MCP shows a disc mark instead of number marks. Why did you do that?

I like to use correct semantic markup and nice styles on the same time. Both widgets list some content sorted by date or amount, so they are ordered lists, and not unordered. But, Recent comments, even more when titled comments are present, don't fit well with list marks, while Most Commented Posts wouldn't be nice being listed with numbers. Well at least in my theme.

These styles are added directly to the HTML document, in 'wp_head' action, that's the same behavior of WordPress Core's Recent Comments widget. If you wanna change it, just add your own style in your theme's style.css and override them. :)

You your ERC widget allows to exclude users from being listed, but MCP doesn't?

It's all database related. For Recent Comments, it's just a matter of defining comment's autor to be excluded, and MySQL does the trick easily because each comment has its author name on it.

For Commented Posts, on the other hand, each post has a field informing how many comments it has, and this field is easy to use. If I'd make specific commenters be excluded, I'd have to ignore this field, make a join between wp_posts and wp_comments based on post ID, and then exclude each comment whose author name matches those defined to not be counted. This SQL query would be much heavier and I believe it's not worthy. We could use cache to store the query and avoid it being done on every page load, but that would require another plugin to handle cache persistence. Explaining all this (or even worse, explain somebody why his site's page load became a bit slower upon using the widget) wouldn't be nice. Maybe someday I implement the feature, or if somebody asks me for it.

What happens if I don't have ip2nation tables installed and working?

What the plugin does with that is query it for a country related to a IP. If tables are not accessible for any reason, the query will return with error and it'll be ignored.

Without the country code, the flag URL can't be created, generating an error. And even if the code is found, if for some reason the flag can't be accesses, same error will happen.

This error is verified, and if flag is available, its tag is generated and provided. But if flag is unavailable, it will just return a harmless blank string. In HTML document there will be no track of it, and user will just see nothing where the flag would be placed.

Of course, if you are adding the flag or relying on country code or name in your theme, you must be prepared for not receiving them, due to some error or simply the plugin not being active.

Requires: 2.8.0 or higher
Compatible up to: 2.9.2
Last Updated: 2010-6-8
Downloads: 6,025


4 stars
4.5 out of 5 stars


Got something to say? Need help?


Not enough data

0 people say it works.
0 people say it's broken.

100,1,1 100,1,1