Advanced HTML tag regex - HELP!

Any questions involving matching text strings to patterns - the pattern is called a "regular expression."

Moderator: General Moderators

Post Reply
FINIF
Forum Newbie
Posts: 1
Joined: Sat Jul 10, 2010 12:30 pm

Advanced HTML tag regex - HELP!

Post by FINIF »

Here's the HTML of the page I am going to be parsing and I'll try to explain what I need.

< a bunch of html above>
<span class="datetime">February 26, 2010</span> </div>

<p>ARTICLE TEXT HERE</p>

</div><! -- ./ end of article bd -->


So pretty much I need the ARTICLE TEXT.

I'm not very good with regex's but here is what I came up with : still getting errors so I thought I'd ask for some help:

(?<=\<span.*?\<\/div\>)\.*?(?=\/end\s+of\s+article)

Any suggestions?
Post Reply