<frame src="testa.htm" name="navbar" scrolling="no" marginwidth="0" margingheight="O">
<frame src="pippo.htm" title="pippo">
<frame src="pluto.php">
Non hai detto cosa vuoi catturare:
Tutto quello che c'è nel tag?
allora la regex dovrà essere qualcosa del genere:
codice:
/(\<frame[^\>]+\>)/
e il tuo matches verrà riempito cosi:
codice:
Array
(
[0] => Array
(
[0] => <frame src="testa.htm" name="navbar" scrolling="no" marginwidth="0" margingheight="O">
[1] => <frame src="pippo.htm" title="pippo">
[2] => <frame src="pluto.php">
)
[1] => Array
(
[0] => <frame src="testa.htm" name="navbar" scrolling="no" marginwidth="0" margingheight="O">
[1] => <frame src="pippo.htm" title="pippo">
[2] => <frame src="pluto.php">
)
)
Ciao
edit:
occhio che se stampi matches con print_r nella pagina web non vedrai il risultato perchè vengono interpretati i tag, se vuoi vedere il risultato reale usa questo codice:
codice:
echo "<pre>";
echo htmlentities(print_r($matches, true));
echo "</pre>";