title: Using ng-repeat in mailto? (Send mail to multiple recipients by JSON properties)
body: <p>I'm currently working on forms that uses angular, PHP and mySQL to track user entries. I've converted the SQL into regular JSON in this pen <a href="http://codepen.io/StuffieStephie/full/BzmxXd/" rel="nofollow">http://codepen.io/StuffieStephie/full/BzmxXd/</a> so you can see what I'm trying to do. </p>
  
  <p>When I click the <code>Email All {{selected.field}} Volunteers</code> button, I'd like to have a comma separated list of all emails, that match the filter.</p>
  
  <p>I can get a list by using</p>
  
  <pre><code>&lt;b ng-repeat="d in names | filter:filters"&gt;{{d.email}}{{$last ? '' : ', '}}&lt;/b&gt;
  </code></pre>
  
  <p>But how do I email those people? I feel like using <code>ng-href</code> is wrong here. A point in the right direction would be appreciated!</p>
  
  <p>EDIT: Okay, I kinda figured out how to do it by setting the mail link as the text content of the list modal.  But this seems really wonky</p>
  
  <p><code>&lt;a ng-href="mailto:{{emails}}" target="_blank" class="waves-effect waves-light btn margin-bottom-1em"&gt;&lt;i class="material-icons left"&gt;email&lt;/i&gt;Email All {{selected.field}} Volunteers ({{(names | filter:filters).length}})&lt;/a&gt;</code></p>
  
  <pre><code>  $scope.hasChanged = function() {
         $scope.filters = $scope.selected.field;
         $scope.emails = $( "b.theEmails" ).text();
      return $scope.emails;
    }
  </code></pre>
  
  <p>Also, I have to change the drop down filter to run the <code>hasChanged()</code> function so the value of <code>$scope.emails</code> will be assigned. (I tried to give it a value outside of the function but it doesn't seem to work. Any help?</p>