How to apply css class on clicked element of iframe with specific attribute value?
<p>After getting the content of iframe being clicked, it is filtered to get the very first element with custom attribute <code>data-type = filled</code>. But I am not able to apply a class on that particular element.</p>

<p>Here is my code:</p>

<pre><code>var clicked_content = event.target.outerHTML, // gives the content being clicked

content = $(clicked_content).find("*[data-type='filled']:first").andSelf().html(); // this gives me the required content

// this was supposed to add a class to particular element
content.parent.addClass("highlight");
</code></pre>

<p>I also did tried to do it this way:</p>

<pre><code>$(event.target).children().find("*[data-type='filled']:first").andSelf().addClass('highlight');
</code></pre>
