How to capture comments nodeType 8 in IE using JS/jQuery?
<p>I am trying to capture a specific commented line. The following code works ok for every browser except IE of course:</p>

<pre><code>&lt;script&gt;
var llf = jQuery('.select').contents().filter(function() {
return this.nodeType === 8 // Comment node
})[2].nodeValue.replace("LLF: ", "").trim();
console.log(llf);
alert(llf);
&lt;/script&gt;
</code></pre>

<p>And this is the HTML:</p>

<pre><code>&lt;td class="select" nowrap="nowrap" rowspan="3"&gt;
&lt;!-- NON IDEAL REASON:  1 hour time window --&gt;
&lt;b&gt;$423.59&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&amp;#163;267.50&lt;/b&gt;&lt;br /&gt;
&lt;!--  Policy Name: Investment Bank --&gt;
&lt;!--LLF: 1253.12 --&gt; //This is the line I want to capture
</code></pre>

<p>If there is a way to do it for all browsers great but if you can think of a specific solution for IE + conditional comment is also fine.</p>

<p>Thanks!</p>
