Comment Status Variable

Developer

Laisvunas

3rd Party (Commercial)


EE Version Support

  • ExpressionEngine 2

Compatibility

If an item is crossed out, it might be untested, not applicable or incompatible. Contact the developer to be sure.

  • Updater
  • Multi Site Manager
  • Stand Alone Entry Form
  • Low Variables
  • Content Elements
  • Better Workflow
  • Matrix
  • Grid
  • Webservice
  • Publisher

Requirements

  • jQuery for the Control Panel

Add-On Type(s)

Extension

Tags

Using the Comment Status Variable extension you are able to parse {comment_status} variable inside {exp:comment:entries} tag pair.

Using Comment Status Variable extension you are able to parse {comment_status}
variable inside {exp:comment:entries} tag pair.

INSTALLATION

1) Upload the directory “comment_status_variable” to the /system/expressionengine/third_party/
directory on the server.

2) Log in into Control Panel, go to Add-ons > Extensions, find in the list “Comment Status Variable”
and click “Enable”.

3) For this extension to work correctly a hack is necessary. Using FTP program go to
/system/expressionengine/modules/comment/ and download the file mod.comment.php
Find in this file in the function entries() the line

$this->EE->db->select('comments.comment_id, comments.entry_id, comments.channel_id, comments.author_id, comments.name, comments.email, comments.url, comments.location AS c_location, comments.ip_address, comments.comment_date, comments.edit_date, comments.comment, comments.site_id AS comment_site_id, 


and add the string “comments.status, ” to it so that the resulting line would be as follows:

$this->EE->db->select('comments.status, comments.comment_id, comments.entry_id, comments.channel_id, comments.author_id, comments.name, comments.email, comments.url, comments.location AS c_location, comments.ip_address, comments.comment_date, comments.edit_date, comments.comment, comments.site_id AS comment_site_id, 


After this the extension has been installed.

EXAMPLE

You can use the variable {comment_status} for displaying different things depending on comment’s status.

For example you can close inappropriate comments and displau the message “Comment has been removed” in case comment has status “closed”.

{exp:comment:entries entry_id="109" limit="50" orderby="date" sort="desc" paginate="bottom" status="open|closed"}
 {if comment_status == "open"}
 {comment}
 {/if}
 {if comment_status == "closed"}
 This comment has been removed.
 {/if}
{/exp:comment:entries}

Hooks Used

If the add-on is an extension, and ties into ExpressionEngine's core files, it will use ExpressionEngine hooks. We are listing any hooks the add-on uses for developers to have an easier time locating other add-ons that they can reference for their own work.

  1. comment_entries_tagdata

This entry was created October 3, 2013, 11:29 am.
This entry was last updated October 4, 2013, 9:39 am.

Disclaimer: Information about ExpressionEngine add-ons is provided as a service to you, the user, and every member of the ExpressionEngine community. devot:ee is not responsible if you hose, mangle, wreck, or otherwise destroy your EE website by installing an add-on that you found out about at this site, regardless of its rating, Favorites status, commercial or free status, or general popularity. Caveat EEmptor!

Returns: devot:ee has a 30-day return policy on all commercial add-ons sold through devot-ee.com. If you need to return an add-on, do not go to the developer or the developer's site, but rather visit our returns page at https://devot-ee.com/returns to initiate your return. If you have questions, email support@devot-ee.com.

There are no reviews for this add-on yet.

What are you waiting for? Rate it and review it!