title: AngularJS on condition ng-if show SAVE and UPDATE BUTTON
body: <pre><code>&lt;form novalidate&gt;
      &lt;label&gt;Name&lt;/label&gt; 
          &lt;input type="text" name="name" ng-model="newcontact.name" required/&gt;
      &lt;label&gt;Email&lt;/label&gt; 
          &lt;input type="text" name="email" ng-model="newcontact.email" required/&gt;
      &lt;label&gt;Phone&lt;/label&gt; 
          &lt;input type="text" name="phone" ng-model="newcontact.phone" required/&gt;
          &lt;br/&gt;
          &lt;input type="hidden" ng-model="newcontact.id" /&gt;
  
       &lt;input type="button" ng-if="newcontact.id" value="UPDATE" ng-click="saveContact()" /&gt;
       &lt;input type="button" ng-if="!newcontact.id" value="SAVE" ng-click="updateContact()" /&gt;
      &lt;/form&gt;
  </code></pre>
  
  <p>Consider the above form, In this create/edit is using the same template, So i like to show 
  Button names as 'UPDATE' or 'SAVE' based on newcontact.id value.</p>
  
  <p>Need to concentrate only on these :</p>
  
  <pre><code>&lt;input type="button" ng-if="newcontact.id" value="UPDATE" ng-click="saveContact()" /&gt;
           &lt;input type="button" ng-if="!newcontact.id" value="SAVE" ng-click="updateContact()" /&gt;
  </code></pre>
  
  <p>Since angular do not have ng-else, so how to achieve this.</p>
  
  <p>Also need to know.
  2. how you secure business logic from user in AngularJS</p>