HTML export Javascript regular expression and y2k fixes
Jake Maciejewski
maciejej at msoe.edu
Sat Sep 27 19:08:29 MDT 2008
See attached patch.
The regular expressions for date matching have nested parenthesis that
don't work as intended with 4-digit years. In sort_yymmdd, for example,
mtch[2] ends up being the first 2 digits of the 4-digit year, not the
month. The month is assigned to d, and the date is disregarded in the
sort.
I also added ? marks to match 1-digit days (the month part of the
pattern already had this) since sort_yymmdd and the others have checks
for 1-digit days.
Finally, I noticed that the y2k handling code was prepending 19 on
4-digit years, so I made it conditional on the year being 2-digit.
--
Jake Maciejewski <maciejej at msoe.edu>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: javascript_regex_and_y2k_fix.patch
Type: text/x-patch
Size: 1443 bytes
Desc: not available
Url : http://forge.novell.com/pipermail/tellico-users/attachments/20080927/0a7360d2/javascript_regex_and_y2k_fix.bin
More information about the tellico-users
mailing list