<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>

<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body bgcolor="#ffffff" text="#000000">
2010/3/8 20:15 Baiju M &lt;<a href="mailto:baiju.m.mail@gmail.com">baiju.m.mail@gmail.com</a>&gt;:<br>
<div class="im">&gt;<br>
&gt; I can see that you are explicitly using `long` above, so the type<br>
&gt; will be long ?<br>
&gt; What is the value of zope.datetime.time(header) ?<br>
&gt;<br>
&gt; Regards,<br>
&gt; Baiju M<br>
<br>
zope/app/file/browser/file.py<br>
</div>
&gt;&gt;        header= self.request.getHeader('If-
<div id=":hk" class="ii gt"><wbr>Modified-Since', None)<br>
<div class="im">&gt;&gt;        lmt = zope.datetime.time(modified.<wbr>isoformat())<br>
</div>
&gt;&gt;        if header is not None:<br>
&gt;&gt;            header = header.split(';')[0]<br>
&gt;&gt;            try:    mod_since=long(zope.datetime.<wbr>time(header))<br>
&gt;&gt;            except: mod_since=None<br>
&gt;&gt;            if mod_since is not None:<br>
&gt;&gt;                if lmt &lt;= mod_since:<br>
&gt;&gt;                    self.request.response.<wbr>setStatus(304)<br>
&gt;&gt;                    return ''<br>
&gt;&gt;        self.request.response.<wbr>setHeader('Last-Modified',<br>
&gt;&gt;                                      
 zope.datetime.rfc1123_date(<wbr>lmt))<br>
<br>
zope.datetime.time(modified.<wbr>isoformat()) - it is date of change of
a<br>
file transferred from browser.<br>
It is compared to date of change of a file on a server - lmt.</div>
</body>
</html>