ask for a RE pattern to match TABLE in html
Grant Edwards
grante at visi.com
Thu Jun 26 14:07:19 EDT 2008
On 2008-06-26, Stefan Behnel <stefan_ml at behnel.de> wrote:
> oyster wrote:
>> that is, there is no TABLE tag between a TABLE, for example
>> <table >something with out table tag</table>
>> what is the RE pattern? thanks
>>
>> the following is not right
>> <table.*?>[^table]*?</table>
>
> Why not use an HTML parser instead?
Stating it differently: in order to correctly recognize HTML
tags, you must use an HTML parser. Trying to write an HTML
parser in a single RE is probably not practical.
--
Grant Edwards grante Yow! I want another
at RE-WRITE on my CEASAR
visi.com SALAD!!
More information about the Python-list
mailing list