You can use the date function:

date("Y-m-d H:i:s");