So I am trying to find a list of steam ID's in a scraped html file. This is what I have so far but it's not working, it is parsing an html page I saved as text and supposed to be outputting things with below variables and it is outputting a blank page.
<?php
$filein = file('TF2U.txt');
foreach ($filein as $html) {
$pattern = '#.*<a[^>]+href="steamcommunity.com/profiles/([0-9]+)/"#iA';
$matches = NULL;
$match_count = preg_match_all($pattern, $html, $matches);
if ($match_count > 0) {
echo implode($matches[1]);
echo "<br>\n";
}
}
?>
Any help would be awesome, I am not sure what I am missing but it's probably simple.