If text begins or ends with these characters, remove characters
<p>I have a jQuery function with a user input text variable <code>sel</code>. I display the variable like this:</p>

<pre><code>jQuery(this).parent().prev().find('.js-trigger-add-tag-target').text(sel);
</code></pre>

<p>Works fine.</p>

<p>If the variable <strong>begins</strong> or <strong>ends</strong> with any of these characters:</p>

<pre><code>.,?!'"
</code></pre>

<p>I want to to strip those very characters. For example, if <code>sel</code> is:</p>

<pre><code>'Hello world, josh's car.,'
</code></pre>

<p>I want to strip it to:</p>

<pre><code>Hello world, josh's car
</code></pre>

<p>How do I do this in jQuery/javascript? Maybe regex?</p>