Octavian Rasnita wrote:
Hi all,

I want to select all the content of a table from a file using regular
expressions (and not a module).
Can you give me some hints about how can I do this?

Uh, use a module.



For example I have the following text:


<table ...>
    <tr...><td>...</td><td>...</td></tr>
    <tr...><td>...</td><td>...</td></tr>
    <tr><td> <table>... </table></td><td>...</td></tr>
</table>

As you see, I could find more other tables included in this table and I
usually don't know how many are they nor at what level they are included.

Thank you for any hints.

Of course, I am not expecting this selection to be possible with a single
regular expression line, but... who knows.


Short of using a module, check the source code for a module as it will show you at least how to go about it... but then, you would be using a module....


I am not trying to be snotty here, but parsing *any* set of medium-complex strings is difficult, there are to many factors, but something like HTML is incredibly difficult, which is why there are robust modules to do it for you.

If you know your data is going to be fairly structured then about the simplest would be to grab everythiung that is not between < and >.

http://danconia.org


-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to