repeating html:
<div class="container" style="position:relative;">
....
....
....
</div>
<div class="container" style="position:relative;">
....
....
....
</div>
im trying to get each of these into their own array object using preg_match:
$file = file_get_contents('file.html');
$search = '/\<div class="container" style="position:relative;"\>(.*)\<\/div\>\<div class="container" style="position:relative;"\>/s';
preg_match($search,$file,$matches);
echo count($matches);
echo '<pre>';
print_r($matches);
echo '</pre>';
and its just not working... I've had mixed results toying with the regex but the best i get is one result with everything in it
yea im horrid with regexs