Coder Social home page Coder Social logo

itthinx / decent-comments Goto Github PK

View Code? Open in Web Editor NEW
2.0 3.0 4.0 314 KB

Decent Comments shows what people say. Provides widgets, shortcodes and API to display comments including author avatars, links, comment excerpts.

License: Other

PHP 97.69% CSS 1.62% Shell 0.69%

decent-comments's Introduction

=== Decent Comments ===
Contributors: itthinx
Donate link: https://www.itthinx.com/shop/
Tags: comment, comment excerpt, comments, comment shortcode, comment widget, comment excerpts, avatar, comment API, excerpt, excerpts, latest comments, recent comments, shortcode, shortcodes
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 7.4
Stable tag: 1.13.0
License: GPLv3

Decent Comments shows what people say. Provides widgets, shortcodes and API to display comments including author avatars, links, comment excerpts.

== Description ==

__Decent Comments shows what people say.__

If you want to show comments along with their author's avatars _and_ an excerpt of their comment, then this is the right plugin for you.

And it's not limited to just a widget showing recent comments: The plugin provides configurable widgets, shortcodes and an API to display comments in sensible ways, including author avatars, links, comment excerpts ...

Anywhere you place comments, by means of a widget, a shortcode or an API call, you can:

- Show an excerpt or the full comment. You can choose to not show the comment as well.
- Determine the number of words shown for excerpts.
- Set your kind of ellipsis.
- Set the number of comments to show.
- Show the author's avatar and determine its size.
- Sort by author email, author URL, content (what's said in the comment), date, karma or post ... in ascending or descending order.
- Show comments for the current post or for a specific post.
- Show comments for a specific post type.
- Show comments for posts in specific categories, for specific tags, ... (more precisely: the ability to show comments from posts related to one or more terms in a chosen taxonomy).
- and more to come ... got suggestions?

__Feedback__ is welcome!
If you need help, have problems, want to leave feedback or want to provide constructive criticism, please do so here at the [Decent Comments plugin page](https://www.itthinx.com/plugins/decent-comments).

Please try to solve problems there before you rate this plugin or say it doesn't work. There goes a _lot_ of work into providing you with free quality plugins! Please appreciate that and help with your feedback. Thanks!

Follow [@itthinx](https://twitter.com/itthinx) for updates on this and other plugins.

__Translations__

* Catalan translation provided by [Ibidem Group](https://www.ibidemgroup.com)
* Chinese translation provided by Francesco from [in Cina](https://www.in-cina.com)
* French translation provided by Thomas Mur from [Creapage.net](https://www.creapage.net)
* German translation provided by the author [itthinx](https://www.itthinx.com)
* Italian translation provided by Francesco from [in Cina](https://www.in-cina.com)
* Lithuanian translation provided by Vincent G from [Host1Free](https://www.Host1Free.com)
* Portuguese translation provided by [TopCasinoWagering](https://wordpress.org/support/profile/topcasinowagering)
* Russion translation provided by [Igor](https://arahis.com)
* Spanish translation provided by [itthinx](https://www.itthinx.com) and [Ibidem Translations](https://www.ibidem-translations.com)

Many thanks!

== Installation ==

1. Upload or extract the `decent-comments` folder to your site's `/wp-content/plugins/` directory. Or you could use the *Add new* option found in the *Plugins* menu in WordPress.
2. Enable the plugin from the *Plugins* menu in WordPress.

Please also visit the [Decent Comments plugin page](https://www.itthinx.com/plugins/decent-comments) for the latest info.

== Frequently Asked Questions ==

= Can this plugin show excerpts of comments or even full comments? =

Yes!

= Can I choose how many comments are displayed? =

Yes.

= Can I display comments for any post? For the current post? For a specific post? =

Yes. Yes. Yes.

= Does it show author's avatars? =

Yes.

= Can I place more than one comment widget with different settings? =

Yes.

= Does it offer shortcodes? =

Yes. Place your comments anywhere you need them!

= Can I call a function to display comments wherever I need? =

Yes.

= What else does it do? =

It's highly configurable!

Please visit the [Decent Comments plugin page](https://www.itthinx.com/plugins/decent-comments) for the latest info.

If you need something that is not available yet, get in touch. Feedback is welcome!

= Help! =

Get help at the [Decent Comments plugin page](https://www.itthinx.com/plugins/decent-comments).

= I really appreciate this, how can I contribute? =

Please visit the [Decent Comments plugin page](https://www.itthinx.com/plugins/decent-comments) and you should find a way to donate or contribute with feedback and ideas.

Translations are also welcome!

== Screenshots ==

1. Decent Comments widget configuration.

== Changelog ==

For the full changelog see [changelog.txt](https://github.com/itthinx/decent-comments/blob/master/changelog.txt).

== Upgrade Notice ==

Tested with the latest version of WordPress.

decent-comments's People

Contributors

ablancodev avatar itthinx avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

decent-comments's Issues

taxonomy queries in multi-lingual installations are modified to refer to current languag

This may be regarded as a WPML/Polyang issue, and depending on installation requirements this may or may not be a desirable behaviour, however from plugin viewpoint the behaviour is inconsistent depending on the query.

Simple queries - show all comments or show all comments by post type return results for all languages.

Taxonomy queries - are modified to show only comments in the currently selected language.
In my view this is inconsistent and undesirable: and in the marketplace tools like tripadvisor give you the change to see comments in all languages to have a better view of feedback (and you can always translate it), whereas if feedback is separated for each language there is less feedback available for everyone.

To confirm I set up 5 taxonomy queries for the same category, querying using English values, Spanish values or both: all 5 queries resulted in the same SQL being generated, which used 1588 if the current language is English and 1599 if the current language is Spanish
(English 1588=inkstone, Spanish 1599=piedra-tinta), and

Comments by product category id 1588 inkstone:
[decent_comments number="25" taxonomy="product_cat" term_ids="1588"]

Comments by product category id 1599 inkstone Spanish:
[decent_comments number="25" taxonomy="product_cat" term_ids="1599"]

Comments by product category term inkstone:
[decent_comments number="25" taxonomy="product_cat" terms="inkstone"]

Comments by product category term piedra-tinta:
[decent_comments number="25" taxonomy="product_cat" terms="piedra-tinta"]

Comments by product category ids 1588 and 1599 inkstone English and Spanish:
[decent_comments number="25" taxonomy="product_cat" term_ids="1588,1599"]

English view SQL result:
SELECT * FROM wp_comments LEFT JOIN wp_posts ON comment_post_ID = wp_posts.ID WHERE comment_approved = '1' AND comment_type NOT IN ("pingback", "trackback") AND wp_posts.post_type NOT IN ('shop_order','shop_order_refund') AND wp_posts.post_type <> 'shop_webhook' AND comment_post_ID IN ( SELECT DISTINCT ID FROM wp_posts LEFT JOIN wp_term_relationships ON wp_posts.ID = wp_term_relationships.object_id LEFT JOIN wp_term_taxonomy ON wp_term_relationships.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id WHERE wp_term_taxonomy.term_id IN ( 1588 ) ) ORDER BY comment_date_gmt DESC LIMIT 25

Spanish view SQL result:
SELECT * FROM wp_comments LEFT JOIN wp_posts ON comment_post_ID = wp_posts.ID WHERE comment_approved = '1' AND comment_type NOT IN ("pingback", "trackback") AND wp_posts.post_type NOT IN ('shop_order','shop_order_refund') AND wp_posts.post_type <> 'shop_webhook' AND comment_post_ID IN ( SELECT DISTINCT ID FROM wp_posts LEFT JOIN wp_term_relationships ON wp_posts.ID = wp_term_relationships.object_id LEFT JOIN wp_term_taxonomy ON wp_term_relationships.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id WHERE wp_term_taxonomy.term_id IN ( 1599 ) ) ORDER BY comment_date_gmt DESC LIMIT 25

PHP Deprecated warning

Deprecated: Warning message appears (running with WP_DEBUG under PHP7):

Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; Decent_Comments_Widget has a deprecated constructor in wp-content/plugins/decent-comments/class-decent-comments-widget.php on line 30

Threaded comments

Current version lists replies as a normal comment: should either omit replies (list only where comment_parent=0) or thread them, to avoid showing replies out of context.

Enhancement: add information from wp_commentmeta

wp_commentmeta information could be added to comments display.
For example wooCommerce comments include from wp_commentmeta as standard:

  • meta_key=rating (values 1-5)
  • meta_key=verified (values 0-1) [verified owner / purchaser of this post_type='product']

While this is specific to wooCommerce, wooCommerce is sufficiently ubiquitous to provide a standard worth handling, or at any rate a basic generic implementation could be done to handle any/all wp_commentmeta information

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.