1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

regular expression to extract the first 300 words of an article

Discussion in 'General Programming Chat' started by xshadowx, Feb 8, 2015.

  1. xshadowx

    xshadowx Junior Member

    Joined:
    Apr 17, 2010
    Messages:
    151
    Likes Received:
    3
    Hi,

    is there a way to extract the first paragraph from each article? or let's say i was to extract the first 500 strings using REGULAR EXPRESSION, please i need this in regular expression , i dont want to use a site or something

    thank you
     
  2. jamb0ss

    jamb0ss Junior Member

    Joined:
    Feb 9, 2012
    Messages:
    125
    Likes Received:
    46
    Occupation:
    Bots programming
    first N words :: (\A(?:\w+\W+?){N})
     
    • Thanks Thanks x 1