title: Restricting few special characters like %,& and " in input field by ng-pattern
body: <p>I have  a password where It should be minimum 8 character with alpha numeric and symbol except &amp;,",% .I given ng-pattern and restricted few symbols. but when I type &amp; too it is accepting. This ng-Pattern normally works. when you enter &amp; and $ it is accepting both. Whereas it should not allow &amp;. thats my point</p>
  
  <pre><code>&lt;div class="form-group fields col-xs-12 col-sm-6 col-md-4 col-lg-4" ng-class="{'has-error' : (submitted || tForm.password.$dirty || tForm.submitted) &amp;&amp; tForm.password.$invalid }"&gt;
      &lt;input type="password" name="password" placeholder ="Password*" class="form-control1" autocomplete="off"  ng-model="model.password" ng-minlength="8" ng-maxlength="20" required ng-pattern="/(?=.*[a-z])(?=.*[A-Z])(?=.*[!@#$^*)(._-])(?=.*[^a-zA-Z._-])(?=.*[^a-zA-Z._-])/"  /&gt;
  &lt;div ng-show="!tForm.password.$error.required &amp;&amp; (tForm.password.$error.minlength || tForm.password.$error.maxlength) &amp;&amp; tForm.password.$dirty" class="help-block"&gt;Passwords must be between 8 and 20 characters.&lt;/div&gt;
         &lt;div ng-show="!tForm.password.$error.required &amp;&amp; !tForm.password.$error.minlength &amp;&amp; !tForm.password.$error.maxlength &amp;&amp; tForm.password.$error.pattern &amp;&amp; tForm.password.$dirty" class="help-block"&gt;Must contain one lower &amp;amp; uppercase letter, number and one non-alpha character (except %,",")&lt;/div&gt;
        &lt;div ng-show="(submitted &amp;&amp; tForm.password.$error.required) " class="help-block"&gt;password is required.&lt;/div&gt;
         &lt;/div&gt;
  </code></pre>