I have been given an XML data feed containing dates which look like this:
<pubDate>Mon, 10 Aug 2015 19:23:30 +0000</pubDate>
I need to convert that into Y-m-d H:i:s for insert via WordPress' wp_insert_post which requires that format. Its very strict, I tried using "8" for August and it errored out, required me to use "08".
My question is, what is the best way to go about this? I could obviously pick it apart piece by piece with a bunch of PHP script but that seems wasteful. Is there a better way?