Happy New Year
I would like to wish all visitors a happy new year, be careful with the fireworks
.
I would like to wish all visitors a happy new year, be careful with the fireworks
.
This is the code needed in cbaddComment:
#Send notify mail to blog admin
try:
to_addr = context.getNotify_to()
from_addr = context.getNotify_from()
msgbody = context.translate('comment_notify_body')
elements = {}
for k in ('title','author','url','body'):
if REQUEST.form.has_key(k):
elements[k] = REQUEST.form[k]
else:
elements[k] = ''
elements['post_ip'] = REQUEST.getClientAddr()
elements['entry_url'] = context.absolute_url()
msgbody = msgbody % (elements)
msgsubject = context.translate('comment_notify_title')
mgsheader = """To: %s
From: %s
Mime-Version: 1.0
Content-Type: text/plain; Charset=utf-8
""" % (to_addr,from_addr)
cbtool.send_mail(mgsheader+msgbody, to_addr, from_addr, msgsubject)
# check status of notification mail setting
if context.getSend_comment_notification():
#Get email addresses for commentators
com_list = context.getComment()
addr_list = []
for com in com_list:
if not addr_list.count(com.getEmail()):
addr_list.append(com.getEmail())
#Send notify mail if need to commentators
try:
for addr in addr_list:
if addr == REQUEST.form['email']:
continue
else:
to_addr = addr
from_addr = context.getNotify_from()
msgbody = context.absolute_url()
msgsubject = context.translate('comment_notify_title')
mgsheader = """To: %s
From: %s
Mime-Version: 1.0
Content-Type: text/plain; Charset=utf-8
""" % (to_addr,from_addr)
cbtool.send_mail(mgsheader+msgbody, to_addr, from_addr, msgsubject)
except Exception,e:
log( 'COREBlog2/cbaddComment: '
'Some exception occured, %s' % e )
except Exception,e:
log( 'COREBlog2/cbaddComment: '
'Some exception occured, %s' % e )
Replaces:
#Send notify mail if need
if context.getSend_comment_notification():
try:
to_addr = context.getNotify_to()
from_addr = context.getNotify_to()
msgbody = context.translate('comment_notify_body')
elements = {}
for k in ('title','author','url','body'):
if REQUEST.form.has_key(k):
elements[k] = REQUEST.form[k]
else:
elements[k] = ''
elements['post_ip'] = REQUEST.getClientAddr()
elements['entry_url'] = context.absolute_url()
msgbody = msgbody % (elements)
msgsubject = context.translate('comment_notify_title')
mgsheader = """To: %s
From: %s
Mime-Version: 1.0
Content-Type: text/plain; Charset=utf-8
""" % (to_addr,from_addr)
cbtool.send_mail(mgsheader+msgbody, to_addr, from_addr, msgsubject)
except Exception,e:
log( 'COREBlog2/cbaddComment: '
'Some exception occured, %s' % e )
The last couple of weeks there have been quite few entries, this is mainly due to these two causes,
1. It have been quite intense at work in combination with “winter tiredness”.
2. I’m evaluating another Plone blog software, it’s a software i used to use but it had some bugs which made me change from it to this one, but now i have Plone upgrade problems with this one, if i upgrade plone the multi language function is not working, which i really like.
If you install IE7 and have a site powered by plone you will notice a slight problem, IE7 will notice you that you will have to accept the use of the plug-in for MSXML 5.
The reason for this is that MS by some reason have marked MSXML as insecure and will warn before using this plug-in, the nice thing is that the earlier versions of are not affected by this.
I fixed this by searching for files which referred to MSXML (HTTPXML.5), this lead me to a file named “sarissa.js” which could be found in a couple of places, i edited this file and removed the references to MSXML 5 .
I restarted zope and made a ctrl+F5 refresh in IE7 and everything worked without warnings, plone / IE7 will use an earlier xml version instead.
I cant guaranty that this will not affect anything else, but it seems to work just fine for me.
I just installed a cashing function which should speed up my web site, when i try it my self I experience it as a substantial improvement in loading time.
Edit: not relevant any more as i use another server and another system.
After trying to allow trackback again and receiving a bunch of spam trackbacks i decided to shut the function off again.
I also added a captcha check to the comment function to prevent it from being miss used as well, I hope this will not be an obstacle for those who actually use it.
Edit: I will try some filtering of the trackbacks, hopefully that will be enough.
I added support for RSS2 today i hope it will work ok:
RSS as previously:
http://zoone.se/main/blog/RSS
The search function has not been working for a long time now, it was crashed due to an update, it should be fixed now and searching should work as well.
Today i got yet another spam trackback on this site, now I’m feed up with it and shuts the trackback function off.
Comments will still be open for all until the delete-key is bleeding, i think comments are an important function, trackback has not been used for good purpose at all so i don’t think that will change anything.
You people who reeds the English part of this Blog is as welcome as the Swedish to add comments, i will treat it equally
.