title: Display number of options selected as soon as they are selected using a multiple choice select2
body: <p>So, I have this multiple choice select2 that gets its options via database query and I wanted to show in an input the number of options that are selected. However, I wanted to do it as soon as they are selected and I don't know how to do it. For example, if I choose 2 options and then, later, I decide to add one more, I want the input to change to 3 options selected. Any help is appreciated and if you have other ideas like how I can do similar stuff but not like how I described it your help is appreciated too. Thanks</p>
  
  <pre><code>&lt;select name="select_areas_educ_form" id="select_areas_educ_form" class="form-control js-example-tokenizer" multiple="multiple"&gt;
  &lt;?php foreach ($areas_educacao as $area)
  {
      echo '&lt;option value="'.$area['id_areaeducacao'].'"&gt;'.$area['cod'].' - '.$area['designacao'].'&lt;/option&gt;';
  }
  ?&gt;
  &lt;/select&gt;
  </code></pre>