Got more questions? Find advice on: ASP | SQL | XML | Windows
in Search
Welcome to RegexAdvice Sign in | Join | Help

Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

Last post 12-01-2007, 10:53 AM by Stevezilla00. 5 replies.
Sort Posts: Previous Next
  •  11-30-2007, 5:39 PM 37147

    Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    Platform: javascript

    Input: <div><p>Some text</p><h3><a href ="#">link text here</a></h3></div>

    Output: <h3>link text here</h3>

  •  11-30-2007, 6:06 PM 37149 in reply to 37147

    Re: Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    Duplicating the question won't get it answered differently.


  •  11-30-2007, 6:25 PM 37150 in reply to 37149

    Re: Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    Hello,

     It's perfectly alright to not help, but it's kinda rude to post such comments as it's clearly not a duplicate question.

     
    Anyways,

    I don't expect a solution.

    Peace.
     

  •  11-30-2007, 6:28 PM 37151 in reply to 37150

    Re: Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    Maybe you didn't realize you posted a duplicate question, but this question is clearly a duplicate of:

    http://regexadvice.com/forums/thread/37131.aspx


  •  11-30-2007, 6:33 PM 37152 in reply to 37151

    Re: Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    if you compare the outputs, there is a difference. I am guilty of using similar subjects I agree.
  •  12-01-2007, 10:53 AM 37166 in reply to 37152

    Re: Regex to strip everything except <h3>, <h4> and <h5> tags and the text within these tags

    The questions are very similar. Keep them in one thread. The questions are indeed identical according to the first post in each, since the example code and output given do not indicate any difference unless one were to read through the other thread to see your later clarifications. In any case, I've already more or less answered your questions over there.

    My regex-centric blog :: JavaScript regex tester
View as RSS news feed in XML