Jump to content
Wiki Home
EPrints Home
Bazaar
Files
Main menu
Main menu
move to sidebar
hide
Navigation
Front Page
EPrints 3 Manual
EPrints Training Course
EPrints Glossary
Installing EPrints
How-to Configure EPrints
EPrints 3.2+ API
EPrints 3 Reference
EPrints Plugins
Wiki
All categories
Recent changes
Main Page
Help
EPrints Documentation
Search
Search
Appearance
Log in
Request account
Personal tools
Log in
Request account
Pages for logged out editors
learn more
Contributions
Talk
Editing
Time field
Page
Discussion
British English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{fieldtypes}} == Description == This field is very similar to [[date field]] but allows the inclusion of hours, mintues and seconds. It is used for the various timestamps associated with an eprint record. Times are always stored in UTC and rendered in the local timezone. == Inheritance == * [[Metadata]] ** [[Date field]] *** [[Time field]] == Additional Properties == Same as [[Date field#Additional_Properties|Date fields]] except for {| border="1" cellpadding="3" cellspacing="0" ! Name !! Default Value !! Required? !! Description !! Notes |- | '''min_resolution''' || <tt>second</tt> || NO || Indicates the smallest unit of measure that must be entered to make a value valid. Can be <tt>second</tt>, <tt>minute</tt>, <tt>hour</tt>, <tt>day</tt> <tt>month</tt> or <tt>year</tt>. || Different from [[Date field]] default (<tt>day</tt>). E.g. <tt>day</tt> indicates <tt>year</tt>, <tt>month</tt> and <tt>day</tt> are required and <tt>hour</tt>, <tt>minute</tt> and <tt>second</tt> are optional. |- | '''render_res''' || <tt>second</tt> || NO || Indicates the smallest unit of time that should be rendered for the value. an be <tt>second</tt>, <tt>minute</tt>, <tt>hour</tt>, <tt>day</tt> <tt>month</tt> or <tt>year</tt>. || Different from [[Date field]] default (<tt>day</tt>). This is not too useful in configuring the field, but can be set as a print option inside citation files. Although it can be handy to store the time right down to the second, you often will just want to render the hours and minutes for day to day use. |- | '''render_style''' || <tt>long</tt> || NO || Whether to render time in <tt>long</tt> or <tt>short</tt> format. || Same default value as [[Date field]]. However, if <tt>long</tt> then renders like <tt>8 September 1998 23:12:11 +01:00</tt>. If <tt>short</tt> then renders like <tt>08 Sep 1998 23:12:11</tt>. |} == Required Phrases == No additional phrases beyond those required for [[Date field#Required_Phrases|Date fields]]. == Database == fieldname_year SMALLINT(6) fieldname_month SMALLINT(6) fieldname_day SMALLINT(6) fieldname_hour SMALLINT(6) fieldname_minute SMALLINT(6) fieldname_second SMALLINT(6) == API == See [[API:EPrints/MetaField/Time|API page]]. == Examples == Most basic example. { name => 'timestamp', type => 'time', } Only render valyes down to the nearest minute. { name => 'datestamp', type => 'time', render_res => 'minute', } Render date and time in short form. { name => 'timestamp', type => 'time', render_style => 'short', } Render date and time in short form. { name => 'datestamp', type => 'time', render_style => 'short', } Require minimum resolution to be to the hour. { name => 'timestamp', typ e=> 'time', min_resolution => 'hour', }
Summary:
Please note that all contributions to EPrints Documentation may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
EPrints Documentation:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Fieldtypes
(
edit
)
Template:RefLinks
(
edit
)