jQueryを使用しています。次の html フラグメントがあります。
<h1>Main Title</h1>
<h2>One header</h2>
<p>some text</p>
<p>more text</p>
<ul><li>a list</li></ul>
<h2>Another header</h2>
<a href="######">one link</a>
<h3>ddd</h3>
<p>eee</p>
<h2>Header 3<h2>
<p>This is a Paragraph</p>
次のようなことを行うには、すべての h2 要素の間にあるコンテンツを取得する必要があります。
First Section text
some text
more text
Second section text
one link
ddd
eee
Third section text
This is a Paragraph
このリソースを読みました: http://www.tutorialspoint.com/jquery/jquery-selectors.htm
しかし、私が必要とすることを行う方法がまだわかりません。
前もって感謝します!