Logo Search packages:      
Sourcecode: zope-coreblog version File versions

def zope-coreblog-1.0::Entry::Entry::forgetPersonalInfo (   self,
  REQUEST = None 
)

reset cookies for posting comment 

Definition at line 555 of file Entry.py.

00555                                              :
        """ reset cookies for posting comment """
        #reset cookie
        resp = REQUEST.RESPONSE
        #path = join(self.aq_parent.getPhysicalPath(),'/');
        path = "/"
        gtime = gmtime(time())
        gtup = (gtime[0] + 1,12,31,23,59,59,0,365,0)
        exp = strftime('%A, %d-%b-%y %H:%M:%S GMT',gtup)

        #exp = (self.ZopeTime() + 365).rfc822()
        resp.setCookie('comment_author','',expires=exp,path=path)
        resp.setCookie('comment_email','',expires=exp,path=path)
        resp.setCookie('comment_url','',expires=exp,path=path)

        if REQUEST:
            return REQUEST.RESPONSE.redirect(REQUEST['HTTP_REFERER'])


    security.declareProtected(ManageCOREBlog, 'editComment')


Generated by  Doxygen 1.6.0   Back to index