Re: [greenstone-users] Display a range of date (yyyy-yyyy) in dc.date meta

From Katherine Don
DateFri, 25 Aug 2006 17:06:45 +1200
Subject Re: [greenstone-users] Display a range of date (yyyy-yyyy) in dc.date meta
In-Reply-To (44EE2B1A-20905-cs-waikato-ac-nz)
Hi Ruben and list,

I have just modified the code so that [Date] outputs the raw date, while
[format:Date] outputs the pretty version.
The date format accepted for DateList and date formatting is now
yyyymmdd or yyyy-mm-dd.
[format:Date] uses a macro day _textmonthmonth_ year so the
formatting can be easily changed in macro files.

For your situation (e.g. 2001-2003) the formatting won't work, but at
least you'll be able to output the Date without it getting mucked up.

This will be available in the next release, coming soon...

Regards,
Katherine

Katherine Don wrote:
> Hi Ruben
>
> Is your problem that when greenstone comes to display the metadata, it
> formats it strangley?
> Currently the code will try to turn any Date metadata into a pretty
> format, eg 20060102 will be displayed as 2 January 2006
> Obviously, this doesn't work if the date is not in that format.
> One of the things we need to do is to make this formatting optional.
>
> In the meantime, you have two options.
> 1. Edit the source code and either turn off the special formatting or
> make it handle your format. The formatting code is format_date() in
> src/recpt/formattools.cpp.
>
> 2. Use a different metadata element for your Dates. Something that is
> not xx.Date.
>
> I'll try and add something for the next release so that you can display
> the raw value if you want to.
>
> Regards,
> Katherine
>
> ruben pandolfi wrote:
>
>>Hi All,
>>
>>I would like to display more than one date in dc.date.
>>
>>At the moment it does not work, as I think the metadata
>>
>>dc.date
>>
>>only accept one value.
>>
>>Would it be possible to display two values in dc.date field?
>>
>>This is to display a document date range:
>>
>>title: mytitile collection
>>author: thisauthor
>>date: 1900-1920
>>
>>meaning that this document refers to the years from 1900 to 1920
>>
>>Is there a way to achieve this without making date field repeatable?
>>
>>Thank you,
>>
>>Ruben
>>
>>_______________________________________________
>>greenstone-users mailing list
>>greenstone-users@list.scms.waikato.ac.nz
>>https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users
>>
>>
>
>
> _______________________________________________
> greenstone-users mailing list
> greenstone-users@list.scms.waikato.ac.nz
> https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users
>
>