Menu

#5 FAQ Revised Time Incorrect

open
nobody
None
5
2004-11-12
2004-11-12
David May
No

Hi,

Great script! It makes maintaining faqs trivial. I love it.

I actually wrap it with a php script (passthru
("makefaq.py -o STDOUT") and it works great.

One thing that I did notice is that the FAQ Revised date
is actually the time that makefaq.py is run rather than
the last modified time of the .dat file, which is the
actual last revised date. This can be "fixed" by simply
changing the localtime(time()) call in PrintTimeStamp to

localtime(os.stat(cfg.infile)[ST_MTIME])

For this to work you'll have to add

import os, sys
from stat import ST_MTIME

Just a suggestion (I've already changed my script),
David

Discussion


Log in to post a comment.