How to select element has attribute and attribute not equal to specific value using jquery?
<p>I got the following line:</p>

<pre><code>$("element").find("[attr!='val'][attr!='val'][attr!='val'][attr!='val'][attr!='val']") 
</code></pre>

<p>based on <a href="https://stackoverflow.com/questions/10687131/jquery-select-by-attribute-using-and-and-or-operators">this</a> answer.
My page stops running. My assumption is that it finds all the different elements in the page, also the ones that don't have the attribute. Is that correct?
If so how can I fix this?
I tried the </p>

<pre><code>$("element").not("[attr='val']") 
// instead of 
$("element").find("[attr!='val']")
</code></pre>

<p>and it still crashed the page.
The following code works of course:</p>

<pre><code>$("element").find("[attr='val']")
</code></pre>