From d2d13b97f9dcae282fe47477915da4d9be64aa9c Mon Sep 17 00:00:00 2001 From: garvinhicking Date: Tue, 28 Jun 2005 08:27:56 +0000 Subject: [PATCH] pass email to plugin hook so that gravatar et al can be used --- .../serendipity_plugin_comments.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plugins/serendipity_plugin_comments/serendipity_plugin_comments.php b/plugins/serendipity_plugin_comments/serendipity_plugin_comments.php index e41a074..1cc8548 100644 --- a/plugins/serendipity_plugin_comments/serendipity_plugin_comments.php +++ b/plugins/serendipity_plugin_comments/serendipity_plugin_comments.php @@ -46,7 +46,7 @@ class serendipity_plugin_comments extends serendipity_plugin $propbag->add('description', PLUGIN_COMMENTS_BLAHBLAH); $propbag->add('stackable', true); $propbag->add('author', 'Garvin Hicking'); - $propbag->add('version', '1.1'); + $propbag->add('version', '1.2'); $propbag->add('requirements', array( 'serendipity' => '0.8', 'smarty' => '2.6.7', @@ -138,7 +138,8 @@ class serendipity_plugin_comments extends serendipity_plugin c.id AS comment_id, c.type AS comment_type, c.url AS comment_url, - c.title AS comment_title + c.title AS comment_title, + c.email AS comment_email FROM '.$serendipity['dbPrefix'].'comments AS c, '.$serendipity['dbPrefix'].'entries AS e WHERE e.id = c.entry_id @@ -166,7 +167,8 @@ class serendipity_plugin_comments extends serendipity_plugin $user = htmlspecialchars(strip_tags($row['user'])); } - $entry = array('comment' => wordwrap($comment, $wordwrap, "\n", 1)); + $entry = array('comment' => wordwrap($comment, $wordwrap, "\n", 1), + 'email' => $row['comment_email']); serendipity_plugin_api::hook_event('frontend_display', $entry); printf( PLUGIN_COMMENTS_ABOUT, -- 2.39.5