Possible Duplicate:
RegEx match open tags except XHTML self-contained tags
I have to map multiple <td> data in a single <tr> using regex in python
for example
<tr>
<td>data 1</td>
<td>data 2</td>
<td>data 3</td>
</tr>
I want to extract data1,data2, data3 using a single regular expression. And there can be any number of <td> tags.
Currently I'm using multiple regex ie first I'm mapping <tr></tr> and then <td></td>
Can I do it in single expression?
I want to achieve this using regex, so I can't use beautiful soup or other html parsers.