Consider the following HTML structure for a specific type of blog post editor:
<div class="entry">
<div class="title" contenteditable="true">
<h2>Title goes here</h2>
</div>
<div class="content" contenteditable="true">
<p>content goes here</p>
</div>
</div>
I am attempting to utilize jQuery to target the .title and .content divs in order to apply unique event handlers to each.
$('[contenteditable]').on(...);
This approach works for both elements, however,
$('[contenteditable] .title').on(...);
and
$('.title').attr('contenteditable', 'true').on(...);
both fail to accurately select the desired contenteditable block.