Let's say I have a string that contains HTML code. Part of this code contains the preheader of an email. How would I extract the text in-between <div class="preheader" style="font-size: 1px; display: none !important;">
and closing </div>
? Assume the opening and closing divs will always remain the same, only the content in-between changes.
some html preceding...
<div class="preheader" style="font-size: 1px; display: none !important;">Email preheader content</div>
some html following...