最里正匹配
<table>
<table>
<table>
<tr> <td> a </td> </tr>
</table>
</table>
</table>
求最里正匹配的法
如上所示,怎得到
<table>
<tr> <td> a </td> </tr>
</table>
即最里 <table> </table> 容
[解决办法]
<table(\s+[^> ]+)?> (?![\s\S]* <table(\s+[^> ]+)?> )[\s\S]*? </table>