I'm workin' too hard on new version and can say that it will be released ASAP. But I need to make some changes in language files and update translations. If you need this feature I could explain how to implement it.
1. Open file /components/com_jcomments/jcomments.php
2. Find and remove code:
if ($config->getInt('comments_locked', 0) == 1) {
$config->set('enable_rss', 0);
$tmpl->addVar('tpl_index', 'comments-form-locked', 1);
}
3. Find and replace code:
$commentsCount = JCommentsModel::getCommentsCount($object_id, $object_group);
with
$commentsCount = JCommentsModel::getCommentsCount($object_id, $object_group);
$commentsPerObject = $config->getInt('max_comments_per_object');
if ($commentsPerObject != 0 && $commentsCount == $commentsPerObject) {
$config->set('comments_locked', 1);
}
if ($config->getInt('comments_locked', 0) == 1) {
$config->set('enable_rss', 0);
$tmpl->addVar('tpl_index', 'comments-form-locked', 1);
}
4. Open file /administrator/components/com_jcomments/admin.jcomments.html.php
5. Find code:
<tr align="left" valign="top">
<td><?php echo JText::_('AP_ENABLE_NESTED_QUOTES'); ?></td>
<td><?php echo JCommentsHTML::yesnoSelectList( 'cfg_enable_nested_quotes', 'class="inputbox"', $config->get('enable_nested_quotes'), JText::_('A_YES'), JText::_('A_NO')); ?></td>
<td><?php echo JText::_('AP_ENABLE_NESTED_QUOTES_DESC'); ?></td>
</tr>
and insert after it:
<tr align="left" valign="top">
<td><?php echo JText::_('AP_MAX_COMMENTS_PER_OBJECT'); ?></td>
<td><input type="text" class="inputbox" size="5" name="cfg_max_comments_per_object" value="<?php echo $config->getInt('max_comments_per_object'); ?>" /></td>
<td><?php echo JText::_('AP_MAX_COMMENTS_PER_OBJECT_DESC'); ?></td>
</tr>
6. Open file /components/com_jcomments/jcomments.ajax.php
7. Find code:
$values = JCommentsAJAX::prepareValues( $_POST );
$userIP = $acl->getUserIP();
add after:
$object_group = trim(strip_tags($values['object_group']));
$object_group = preg_replace('#[^0-9A-Za-z\-\_\,\.]#is', '', $object_group);
$object_id = isset($values['object_id']) ? intval($values['object_id']) : '';
$commentsPerObject = $config->getInt('max_comments_per_object');
if ($commentsPerObject > 0) {
$commentsCount = JCommentsModel::getCommentsCount($object_id, $object_group);
if ($commentsCount == $commentsPerObject) {
$message = $config->get('message_locked');
if (empty($message)) {
$message = $config->get('ERROR_CANT_COMMENT');
}
$message = JCommentsAJAX::escapeMessage($message);
$response->addAlert($message);
return $response;
}
}
Thats all. After this you'll need to set this parameter in JComments settings.