Hello everyone...
I have another little problem...
I have the following code
$mask = '![clause].*[/clause]!U';
$found = preg_match_all($mask, $contentdata, $matches);
$result = count($matches[0]);
$result = count($matches[0]);
$start = 0;
while ($start < $result) {
$tmpstring = str_replace("<clause>","",$matches[0][$start]);
$tmpstring = str_replace("</clause>","",$tmpstring);
$start++;
}
Now this code will match
"This is some text with a [clause]this that the other[/clause] and some other stuff"
and return "this that the other" for me to process
however if it will not pickup
"This is some text
[clause]
this is some
and so is this
[/clause]
because it can"
I would like the code to look at the previous text and return:
"this is some
and so is this"
Any ideas... im not very experienced with regular expressions, can anyone help ?
Thanks
Chris