2ge has asked for the wisdom of the Perl Monks concerning the following question:
Hello guys,
I am using this great module for parsing, I like it, it is quite easy, but now I get into trouble - really dont know how to parse following:<!-- some other divs and so here --> <div class="full"> <div class="content"> <ul class="topics"> <-- I want extract these links div class "full" only --> <li><a href="foobar">foobar</a></li> <li><a href="foobr2">fobar2</a></li> <li><a href="fobar3">foobr3</a></li> </ul> </div> </div> <div class="otherclass"> <div class="content"> <ul class="topics"> <-- I DO NOT WANT these links --> <li><a href="fbaor">fbaor</a></li> <li><a href="fabar2">fabar2</a></li> <li><a href="fbar3">fbar3</a></li> </ul> </div> </div> <!-- some other divs and so here -->
I read all nodes posted here, also tutorial. Main trouble is, I dont know create while() loop only for <div class="full"> html code - if I knew this, I would write such a parser.
thanks for any help
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: easy HTML::TokeParser help request
by Fletch (Bishop) on Aug 03, 2006 at 13:16 UTC | |
by 2ge (Scribe) on Aug 03, 2006 at 13:27 UTC | |
by GrandFather (Saint) on Aug 03, 2006 at 19:35 UTC | |
by Fletch (Bishop) on Aug 03, 2006 at 13:33 UTC | |
by 2ge (Scribe) on Aug 03, 2006 at 14:21 UTC | |
by Fletch (Bishop) on Aug 03, 2006 at 14:42 UTC | |
| |
|
Re: easy HTML::TokeParser help request
by wfsp (Abbot) on Aug 03, 2006 at 16:21 UTC | |
|
Re: easy HTML::TokeParser help request
by un-chomp (Scribe) on Aug 03, 2006 at 14:56 UTC | |
by 2ge (Scribe) on Aug 04, 2006 at 12:12 UTC |