View Single Post
Old 06-09-2002, 11:15 PM   #5 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,505
sde is on a distinguished road
lets look at this a little different:

<?
// this brings each line from test.html into an array "html[]"
$html = file("test.html");

// this brings all elements from the array $html[] into one variable named $string
$string = implode("", $html);

// this takes all places where there are 4 hr tags.. and make them 2
$string=str_replace("<hr><hr><hr><hr>","<hr><hr>", $string);

// now explode $string into an array
$array=explode("<hr><hr>",$string);
?>

hehe, how fun .. i didn't test this, but i think it might work.

Last edited by sde; 06-09-2002 at 11:21 PM.
sde is offline   Reply With Quote