1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
| <?php
$str = <<< EOS
<a class=cl style="left:230;top:300" href=javascript:void(0); onclick="return overlib('<b>Action :</b><LI><a href=soigner.php?xc=77&yc=101&t=p&idc=14641 target=f2>Soigner (9 PA)</a><LI><a href=choix_ench.php?t=1&d=2&xc=77&yc=101&idc=14641 target=f2>Enchanter</a>
<li><a href=msg_frame.php?x=2&dest=Kezar target=f2>Message</a><li><a href=rp_show.php?idc=14641 target=f2>Consulter son profil</a>',STICKY, CAPTION,'77 / 101 distance : 2',FGCOLOR,'#CCCCFF');" onmouseover="return overlib(' <b>77 / 101 </b> distance : 2<br><hr><b>Kezar</b>, Nécromant Elfe <br><u>Niveau :</u> <b>27</b><br><u>Escouade :</u> Oskorei<br><u>Pv :</u> 517 / 517<hr><u>Enchantement(s) actif(s) :</u> <br><img src=img/s/feline.gif> 03/07 à 20:12<br><img src=img/s/resist.gif> 03/07 à 18:40<br><img src=img/s/a12.gif> 02/07 à 12:31<hr><b>Message allié :</b> yobb 1po Kael 4p Coks1 Ryujinn2 nausica 1 vreanor 1 benio 2 Silgalind2 Shandor1cromagnon 3 nempite2',FGCOLOR, '#CCFFFF');" onmouseout="return nd();"><img class=bg src="img/t/0.gif"/><img class=pj src="img/p/0/2/0_29.gif" width=40/><img class=ov src="img/n/n0.png"/></a>
<a class=cl style="left:230;top:300" href=javascript:void(0); onclick="return overlib('<b>Action :</b><LI><a href=soigner.php?xc=77&yc=101&t=p&idc=14641 target=f2>Soigner (9 PA)</a><LI><a href=choix_ench.php?t=1&d=2&xc=77&yc=101&idc=14641 target=f2>Enchanter</a>
<li><a href=msg_frame.php?x=2&dest=Kezar target=f2>Message</a><li><a href=rp_show.php?idc=14641 target=f2>Consulter son profil</a>',STICKY, CAPTION,'77 / 101 distance : 2',FGCOLOR,'#CCCCFF');" onmouseover="return overlib(' <b>77 / 101 </b> distance : 2<br><hr><b>Kezar</b>, Nécromant Elfe <br><u>Niveau :</u> <b>27</b><br><u>Escouade :</u> Oskorei<br><u>Pv :</u> 517 / 517<hr><u>Enchantement(s) actif(s) :</u> <br><img src=img/s/feline.gif> 03/07 à 20:12<br><img src=img/s/resist.gif> 03/07 à 18:40<br><img src=img/s/a12.gif> 02/07 à 12:31<hr><b>Message allié :</b> yobb 1po Kael 4p Coks1 Ryujinn2 nausica 1 vreanor 1 benio 2 Silgalind2 Shandor1cromagnon 3 nempite2',FGCOLOR, '#CCFFFF');" onmouseout="return nd();"><img class=bg src="img/t/2.gif"/><img class=pj src="img/p/0/2/0_29.gif" width=40/><img class=ov src="img/n/n1.png"/></a>
EOS;
$motif='#<a class=cl [^>]* (?:onmouseover|onclick)="(return overlib[^"]+)"[^>]*(?:onmouseover|onclick)="(return overlib[^"]+)" [^>]*>(.*?)</a>#is';
preg_match_all($motif, $str, $out, PREG_PATTERN_ORDER);
$overlibs = array_merge($out[1], $out[2]);
foreach($overlibs as $str) {
$reg = '#href=([^\s]+)#i';
if ( preg_match_all($reg, $str, $match) ) print_r($match[1]) ;
}
print_r($out[3]); |
Partager