So I am pulling some data from a internal jsp page with DOMDocument and using a php script to insert that into a database. It pulls the data and I have so far got everything the way I want it, but the time that is output on the page, which is in a string format is in the following format:
12:05:00a //for am
10:15:00p //for pm, obviously
I was thinking I could use strtotime (but I'm open to suggestions). Here is how it is coded:
$cols = $row->getElementsByTagName('td');
$scheduled_time = $cols->item(0)->nodeValue;
echo $scheduled_time;
I know the answer probably very easy, but I haven't had to work much with converting times. It can be in military time as well.
Thanks in advance.