
smith_t at denison
Jul 11, 2008, 6:10 AM
Post #3 of 7
(201 views)
Permalink
|
Thanks for the info, however it doesn't seem to be working for me. This is my initial line of code: $enddate = $element->get_field('end_date')->get_value(); OUTPUT => 2002-01-07 00:00:00 And then this is then line with what you gave me, just in case I formatted it wrong: $enddate = $element->get_field('end_date')->get_value(undef, Bric::Config::ISO_8601_FORMAT); OUTPUT => 2002-01-07 00:00:00 So this doesn't seem to be working for me. Any other suggestions? Thanks. -Trevor On Thu, Jul 10, 2008 at 6:48 PM, David E. Wheeler <david[at]kineticode.com> wrote: > On Jul 10, 2008, at 12:31, Trevor Smith wrote: > >> Even though Bricolage provides a nice way for us to format the date I >> am having an impossible time trying to figure out how to just return a >> UTC compliant date/time from a date input field. I need to use it to >> render an UNTIL time in my Recurrence Rule. I probably just missed >> something simple, hope someone can help. > > > For a date field, I believe it's: > > $field->get_value(undef, Bric::Config::ISO_8601_FORMAT); > > For an attribute, like cover_date, its: > > $story->get_cover_date(Bric::Config::ISO_8601_FORMAT); > > HTH, > > David >
|