|
List Info
Thread: Comment reply handling
|
|
| Comment reply handling |

|
2006-12-16 20:43:05 |
|
Hi,
I have been wondering if CoreBlog2 only sends the notification mail to the email set in the blog settings or if it mails a notice to the prior commentators for that post as well, my guess would be the first option.
If so would it be possible to change the behavior to send a notice mail to the prior commentators as well?
-- With best regards / med vänlig hälsning
Niklas
|
| Comment reply handling |

|
2006-12-17 05:07:18 |
Hi,
> If so would it be possible to change the behavior to
send a notice mail
> to the prior commentators as well?
How about customizing
/plone/portal_skins/COREBlog2/cbaddComment?
Regards,
--
Yusuke NAKAI
mail: nyusuke nagosui.org
web : http://nagosui.org
_______________________________________________
COREblog-en mailing list
COREblog-en postaria.com
http
://postaria.com/mailman/listinfo/coreblog-en
Unsubscription writing to coreblog-en-leave postaria.com
|
|
| Comment reply handling |

|
2006-12-18 10:01:37 |
|
I guess thats a yes to my first question?
I would really like to do it, but my programming skills is limited at a very low level for now, but i guess i will have to add it as a feature request.
/Niklas
On 12/17/06, Yusuke NAKAI < nyusuke nagosui.org">nyusuke nagosui.org> wrote:
Hi,
> If so would it be possible to change the behavior to send a notice mail > to the prior commentators as well?
How about customizing /plone/portal_skins/COREBlog2/cbaddComment?
Regards,
-- Yusuke NAKAI
mail: nyusuke nagosui.org">nyusuke nagosui.org web : http://nagosui.org _______________________________________________ COREblog-en mailing list
COREblog-en postaria.com">COREblog-en postaria.com http://postaria.com/mailman/listinfo/coreblog-en Unsubscription writing to coreblog-en-leave postaria.com">
coreblog-en-leave postaria.com
-- With best regards / med vänlig hälsning
Niklas
|
| Comment reply handling |

|
2006-12-18 16:55:17 |
Hi,
> I would really like to do it,
> but my programming skills is limited at a very low
level for now
Me too!
But you're lucky to get chance to learning python, aren't
you?
First of all, there is a typo in cbaddComment around line
40:
--------------------------------------------------
#Send notify mail if need
if context.getSend_comment_notification():
try:
to_addr = context.getNotify_to()
from_addr = context.getNotify_to() <- here
--------------------------------------------------
This should be:
from_addr = context.getNotify_from()
^^^^^^
Well, let's customize.
You can customize notification mail by assorting these
objects and
setting them to 'to_addr' or 'from_addr'.
- context.getNotify_to()
-> e-mail address entered to 'Notify To' field on
'blog settings'
- context.getNotity_from()
-> e-mail address entered to 'Notify From' field on
'blog settings'
- REQUEST.form['email']
-> e-mail address entered by comment form
Now assuming in your blog settings:
- Notify From: spam example.com
- Notify To: egg example.com
- checked 'Require email'
Let's see some cases.
1.To send notification mail
from spam example.com
to egg example.com,
no customization is needed(default action).
2.To send notification mail
from spam example.com
to person who post comment,
customization in cbaddComment will be like this:
--------------------------------------------------
#Send notify mail if need
if context.getSend_comment_notification():
try:
to_addr = REQUEST.form['email']
from_addr = context.getNotify_from()
--------------------------------------------------
3.To send notification mail
from person who post comment
to egg example.com,
customization in cbaddComment will be like this:
--------------------------------------------------
#Send notify mail if need
if context.getSend_comment_notification():
try:
to_addr = context.getNotify_to()
from_addr = REQUEST.form['email']
--------------------------------------------------
Note: If 'Require email' is 'not' checked in your blog
setting, it seems
to be better to do conditional branch where
'REQUEST.form['email']' appears.
For example, in case 3. on above,
--------------------------------------------------
#Send notify mail if need
if context.getSend_comment_notification():
try:
to_addr = context.getNotify_to()
if REQUEST.form['email'] == "":
from_addr = 'someone_posting_comment example.com'
else:
from_addr = REQUEST.form['email']
--------------------------------------------------
Unfortunately I'm not skilled at programming, so I'm not
confident these
codes help you, and afraid if I misunderstood your
intention. I hope for
someone's following up.
Regards,
--
Yusuke NAKAI
mail: nyusuke nagosui.org
web : http://nagosui.org
_______________________________________________
COREblog-en mailing list
COREblog-en postaria.com
http
://postaria.com/mailman/listinfo/coreblog-en
Unsubscription writing to coreblog-en-leave postaria.com
|
|
| Comment reply handling |

|
2006-12-18 20:33:10 |
|
Thanx for your efforts Mr, NAKAI,
If i understand what you are describing correctly, its not entirely what i wold like to do,
1. I make a post. 2. person A makes a comment in the above post (i get notified).
3. person B makes a comment in the same post, this is where i wold like to have a notification to me (this is what is built in at the moment i think) and person A (i dont think this is implemented). 4. if more comments are added i would like to be notified as well as have notifying mails sent to the persons who already made comments in that post.
/Niklas
On 12/18/06, Yusuke NAKAI < nyusuke nagosui.org">nyusuke nagosui.org> wrote:
Hi,
> I would really like to do it, > but my programming skills is limited at a very low level for now
Me too! But you're lucky to get chance to learning python, aren't you?
First of all, there is a typo in cbaddComment around line 40:
-------------------------------------------------- #Send notify mail if need if context.getSend_comment_notification(): try: to_addr = context.getNotify_to() from_addr = context.getNotify_to
() <- here --------------------------------------------------
This should be: from_addr = context.getNotify_from() ^^^^^^
Well, let's customize.
You can customize notification mail by assorting these objects and setting them to 'to_addr' or 'from_addr'.
- context.getNotify_to() -> e-mail address entered to 'Notify To' field on 'blog settings'
- context.getNotity_from() -> e-mail address entered to 'Notify From' field on 'blog settings'
- REQUEST.form['email'] -> e-mail address entered by comment form
Now assuming in your blog settings:
- Notify From: spam example.com">spam example.com - Notify To: egg example.com">egg example.com - checked 'Require email'
Let's see some cases.
1.To
send notification mail from spam example.com">spam example.com to egg example.com">egg example.com, no customization is needed(default action).
2.To send notification mail
from spam example.com">spam example.com to person who post comment, customization in cbaddComment will be like this: -------------------------------------------------- #Send notify mail if need
if context.getSend_comment_notification(): try: to_addr = REQUEST.form['email'] from_addr = context.getNotify_from() --------------------------------------------------
3.To send notification mail
from person who post comment to egg example.com">egg example.com, customization in cbaddComment will be like this: -------------------------------------------------- #Send notify mail if need
if context.getSend_comment_notification(): try: to_addr = context.getNotify_to() from_addr = REQUEST.form['email'] --------------------------------------------------
Note: If 'Require email' is 'not' checked in your blog setting, it seems
to be better to do conditional branch where 'REQUEST.form['email']' appears.
For example, in case 3. on above, -------------------------------------------------- #Send notify mail if need if context.getSend_comment_notification
(): try: to_addr = context.getNotify_to() if REQUEST.form['email'] == "": from_addr = ' someone_posting_comment example.com">someone_posting_comment example.com
' else: from_addr = REQUEST.form['email'] | |