Timestamp upon update
Timestamp upon update
Hi,
using editor with MySQL. I'd like to have a new column, where a timestamp is inserted every time someone updates a record (basically even the current date is enough too). How could this be achieved in the easiest way, what part(s) of the code should be modified?
Thanks in advance for the answers.
Cheers
p.s. DataTables is great, gives a plethora of options.
using editor with MySQL. I'd like to have a new column, where a timestamp is inserted every time someone updates a record (basically even the current date is enough too). How could this be achieved in the easiest way, what part(s) of the code should be modified?
Thanks in advance for the answers.
Cheers
p.s. DataTables is great, gives a plethora of options.
This discussion has been closed.
Replies
The other option is to have a field defined in the Editor libraries (assuming you are using them) as add the timestamp to the data to be processed by the Editor libraries, before it does the processing (i.e. add it to _POST - or safer, a copy of _POST).
Allan
Did it the first way.
Do you know what should be done if i wanted to have only the date inserted (and not the date and time)?
It would be enough just to see the date in the table/editor itself - can/should something be done to the script/database itself?
Cheers
Allan