Sqlsrv driver return datetime colum as datetime object
MSSQL’s PHP driver sqlsrv_fetch_object return DateTime object by default.
To disable this, pass parameter ReturnDatesAsString on the connection string.
$param = array('Database' => 'db',
'UID' => 'uname',
'PWD' => 'secret',
'ReturnDatesAsStrings' => 'true');
$conn = sqlsrv_connect('localhost\sqlexpress', $param);