Posted on December 15th, 2008 in WP Plugins | 57,367 views

This is a plugin for WordPress 2.6+ that can help you know where your commenters come from, which type of web browser and OS they used when they left a comment on your blog. It provides two functions that take IP and User Agent as parameters and then return HTML string contains country flag, web browser and OS icons. You can put these icons anywhere you like in each comment.

In fact, this plugin is a combination of two plugins: WordPress Browser Detection Plugin and Easy IP2Country that I have intergrated as a built-in plugin for my premium theme before, see this page for example, but now I decide to separate it as a new plugin with some enhancements and share it for everyone. :)

Features:

  • Detects and shows commenter's country flag, web browser and operating system
  • Supports many web browsers and operating systems: major desktop browsers, antiquated browsers, blogging software (for trackbacks and pingbacks), text based browsers, various PDAs and cell phones.
  • Uses a binay file for IP to country resolution and supports database sources from Webhosting.info - Software77.net
  • The returned string can be configed as a template to suite your theme

Screenshot:

comment info detector

Download:

download

Installation:

  1. Download the plugin and extract its content
  2. Upload the complete folder "comment-info-detector" to the "/wp-content/plugins/" directory
  3. Activate the plugin through the 'Plugins' menu in WP-Admin
  4. Go to 'WP-Admin -> Settings -> Comment Info Detector' to configure the plugin

Update:

To update new version for this plugin, please deactivate it => delete the old plugin-folder from your server => upload the new plugin-folder => activate the new plugin.

Usage:

  1. Open wp-content/themes/<YOUR THEME NAME>/comment.php
  2. Find the comment loop:
    1
    
    foreach ($comments as $comment)
  3. Add anywhere you like below the comment loop:
    1
    
    <?php if (function_exists("CID_init")) { CID_print_comment_flag(); echo ' '; CID_print_comment_browser(); } ?>
  4. Optional: you can change the CSS style for flag - web browser - OS icons, open and edit:/wp-content/plugins/comment-info-detector/comment-info-detector.css

Credits

Comment Info Detector is written by me, HieuDT. Big thanks to Priyadi Iman Nurcahyo for web browser, OS detection code and Omry Yadan for IP2Country library.

Changelog:

  • 1.0.0 [12-15-2008]: First released.
  • 1.0.1 [12-16-2008]: Added two quick-tags for web browser and operating system to return result correctly.
  • 1.0.2 [01-12-2009]: Updated database for ip2country library and increase ability to detect some new web browsers - operating systems.
  • 1.0.3 [01-18-2009]: Added two options that automatically display icons, no need to modify comments.php file.
  • 1.0.4 [03-02-2009]: Updated database for ip2country and added icons for IE8, Vista.
  • 1.0.5 [09-07-2009]: Updated database for ip2country and added icons for Windows 7.

Now I still continue to develop this plugin and I'm very glad to receive feedback from you. If you feel this plugin is missing or not working well, you are welcome, please let me know! :D

Sign up for News and Updates!
digg delicious stumbleupon technorati Google live facebook Sphinn Mixx newsvine reddit yahoomyweb

147 Responses to “WP Plugin: Comment Info Detector”

  1. Plugin này trang trí vào site , thank anh hieudt. :grin:

  2. Hi there!

    Plugin looks great! I have two questions for you though.

    1. Is it possible to add this to authors' posts as well?

    2. Is it possible to make the countries work like tags so we can click on them and see all of the posts with that tag?

    Thanks and best wishes,
    Kristen

  3. Probando, uno dos tres

  4. En Google Chrome, no aparece la bandera del país.

    In Google Chrome, do not see the flag of the country.

    Trong Google Chrome, không nhìn thấy lá cờ của đất nước.

  5. hi hieudt, i saw that you have not update this plugin' information for along time, i 've made some upgrade to you plugins, and i want to know if i can Cooperate with this plugin?
    the URL is http://www.hzlzh.com/comment-info-detector/

  6. Flags do not appear after installing this addon:(

  7. Rất cảm ơn bác Hieudt

  8. Hi mình đang học cách sử dụng wp ,vì thế cám ơn bạn rất nhiều !!!!

  9. Chào bạn HieuDT, bạn cho mình hõi, trong file Comments.php của mình ko có vòng lặp "for", vậy mình chèn đoạn code đó vào sao? Hihi, mình mới làm thử blog wp, có gì bạn ghé thăm và chỉ giáo mình nha ^^

  10. hi, do you still update this script ? if you dont mind I'll update this versin to compatible with latest wp version.

  11. Sẽ add vào cái web ^^
    Chừng nào mới có bản 2.0 nhỉ :d

  12. Active rồi add vào wp kiểu gì thế các bạn

  13. I have buddypress default theme.
    where should I put the code? What line? Please help me.

  14. Cảm ơn bác, em cũng đang cần cái này cho nó bắt mắt

  15. Hay quá mình đang cần plugin này cảm ơn nhiều !

  16. I am using Mystique 3.0.4
    in this theme I can't found this code
    then where to add this code plese help.

    foreach ($comments as $comment)

  17. Plugin này tốt đó nó sẽ giúp mình biết được ai đến

Comment Pages:
1 2 3

Leave a Reply

Comment moderation is currently enabled so comments with spammy words or a few links might be delayed. Please do not submit your comments twice, they will be approved soon.
Off Auto TELEX VNI VIQR VIQR*