How take html structure beetween tags
<p>Site have this kind of structure</p>

<pre><code>&lt;div class="main"&gt;
hello world&lt;br /&gt;
againg hello world&lt;br /&gt;
   &lt;h3&gt;some text&lt;/h3&gt;
   &lt;ul&gt;
    &lt;li&gt;again text&lt;/li&gt;
      &lt;li&gt;again text&lt;/li&gt;
   &lt;/ul&gt;
&lt;/div&gt;
</code></pre>

<p>Now, i want take text with all br tags or with same html structure beetween class main and h3.
i used to .prevUntil() but can't do anything</p>
