Search

Does anybody know if there is a way to get the date and time of the last update of an entry? Does Symphony automatically store these information or is there a way to set up a field to log it?

Alistair whipped one up for me on IRC not long ago... let me dig it up.

-- Edit --

Here it is http://pastie.org/208905. I named it field.modifieddate.php and dropped it into the fields folder in symphony/lib/toolkit (I think that's right).

Thank you, I'll try that out tomorrow!

Hm ... I'm not sure if this field is working the way I expect it to work. It automatically selects the current date when creating a new entry but it does not update date and time when resaving the entry.

Have a poke around the function:

public function processRawFieldData($data, &$status, $simulate=false, $entry_id=NULL){

and see that when you save an entry, you're getting in there.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details