You are here

function views_xml_is_date in Views Datasource 5

3 calls to views_xml_is_date()
views_xml_atom_render in ./views_xml.module
views_xml_opml_render in ./views_xml.module
views_xml_raw_render in ./views_xml.module

File

./views_xml.module, line 376
views_xml.module - provides Views plugin for rendering node content as XML.

Code

function views_xml_is_date($input) {
  if (strpos($input, 'a:3:{s:5:"month"') !== 0) {
    return $input;
  }
  else {

    //serialized date array
    $date = unserialize($input);
    return date(DATE_ISO8601, mktime(0, 0, 0, $date['month'], $date['day'], $date['year']));
  }
}