In my code I am trying to extract date/time only from <td>
and then want to convert it into Unix time-stamp but I am stuck at extracting preg_match_all()
function it won't show anything when I use $result[0]
or $result[1]
. I don't know why but when I dump the array I got following result:
My Array
Array
(
[0] => Array
(
[0] => <td align="left" valign="top">02 April 2017 | 05:55 PM</td>
)
[1] => Array
(
[0] => 02 April 2017 | 05:55 PM
)
)
Here is my PHP code
preg_match_all('/<td align="left" valign="top">([^"]*)<\/td>/', $printtable, $result);
var_dump($result);