Zend Certified PHP Engineer 200-550 Question # 20 Topic 3 Discussion

Zend Certified PHP Engineer 200-550 Question # 20 Topic 3 Discussion

200-550 Exam Topic 3 Question 20 Discussion:
Question #: 20
Topic #: 3

Given a DateTime object that is set to the first second of the year 2014, which of the following samples will correctly return a date in the format '2014-01-01 00:00:01'?


A.

$datetime->format('%Y-%m-%d %h:%i:%s')


B.

$datetime->format('%Y-%m-%d %h:%i:%s', array('year', 'month', 'day', 'hour', 'minute', 'second'))


C.

$datetime->format('Y-m-d H:i:s')


D.

$date = date('Y-m-d H:i:s', $datetime);


Get Premium 200-550 Questions

Contribute your Thoughts:


Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.