Changeset 23939 for main/trunk/greenstone2/perllib/doc.pm
- Timestamp:
- 2011-04-20T21:27:19+12:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/perllib/doc.pm
r23923 r23939 126 126 127 127 # set lastmodified for OAI purposes, added by GRB, moved by kjdon 128 sub set_oailastmodified { 129 my $self = shift (@_); 130 131 my $source_path = $self->{'terse_source_path'}; 132 133 if (defined $source_path && (-e $source_path)) { 134 my $current_time = time; 135 136 my ($seconds, $minutes, $hours, $day_of_month, $month, $year, 137 $wday, $yday, $isdst) = localtime($current_time); 138 139 my $date_modified = sprintf("%d%02d%02d",1900+$year,$month+1,$day_of_month); 140 141 $self->add_utf8_metadata($self->get_top_section(), "oailastmodified", $current_time); 142 $self->add_utf8_metadata($self->get_top_section(), "oailastmodifieddate", $date_modified); 143 } 144 } 145 146 # no longer used for OAI purposes, since lastmodified is not what we want as the 147 # Datestamp of a document. This doc metadata may be useful for general purposes. 128 148 sub set_lastmodified { 129 149 my $self = shift (@_);
Note:
See TracChangeset
for help on using the changeset viewer.