Anonymous

Anonymous
In the notification array, can I add 'comment' to alert me when a comment has been contributed to a story? Also, a way to delete inappropriate comments? Thanks again for a wonderful product and your continued support.

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
There is not comment notification currently. The Admin can delete comments. When logged in as Admin, you should see a "delete" option underneath each comment. bye, Dirk

Anonymous

Anonymous
I am looking for comment notification also. Are there any plans to add this option in the next build?

Fernando Ipar

Anonymous
caffeinated
I've made this quick fix, which can be set up with cron to check for new comments and notify you through e-mail. Someone with more geeklog knowledge could probably have it create a proper url with a link to the new comments:
Text Formatted Code

<?php
require "config.php";

# this is a text file where I store the last seen number of comments
define('CNT_FILE','/path/to/geeklog/geeklog_comments');
# this is the destination e-mail for notifications
define('DESTINATION','your@email.com');

$link = mysql_pconnect($_DB_host, $_DB_user, $_DB_pass);
mysql_select_db($_DB_name,$link);

$res = mysql_query("select count(*) as cnt_comments from ".$_DB_table_prefix."comments");
$cnt = 0;
if (file_exists(CNT_FILE)) {
    $cnt = file_get_contents(CNT_FILE);
}

$arr = mysql_fetch_assoc($res);
if ($cnt < $arr["cnt_comments"]) {   
        file_put_contents(CNT_FILE,$arr["cnt_comments"]);
        $rs = mysql_query("select distinct sid from ".$_DB_table_prefix."comments where cid > ".$cnt." order by date desc");
        $msg = "There are new comments in the following stories: ";
        while ($arr = mysql_fetch_assoc($rs)) {
                $msg .= $arr["sid"];
        }
        mail(DESTINATION,"new geeklog comment",$msg);
}

mysql_close($link);
 

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Just wanted to point out that the start of this thread is 5 years old 8)

Comment notifications are part of Jared's Summer of Code project. Alternatively, you could install Mike's plugin for comment feeds.

bye, Dirk