PHP convert separate date and time strings into single datetime -


i have 2 separate strings date , time formatted like: 14/04/2014 , 01:15 pm

i convert these datetime formatted y-m-d h:i:s

any idea how go this??

$date = datetime::createfromformat('d/m/y h:i a', '14/04/2014'.' '.'01:15 pm'); echo $date->format('y-m-d h:i:s'); 

demo


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -