title: AngularJS string replace in HTML
body: <p>In my <code>AngularJS</code> application, I have an issue with string replace in HTML.</p>
  
  <p><strong>Expectation:</strong> </p>
  
  <p>Using the same variable as section title and partial of button's label.</p>
  
  <pre>
  Submitted Forms (Form (13G), Form (12C) and etc.,)
  <kbd>Attach Submitted Forms</kbd>
  
  Planned Plans (Plan (13G), Plan (12C) and etc.,)
  <kbd>Attach Planned Plans</kbd>
  
  Defined Schemes (Scheme (13G), Scheme (12C) and etc.,)
  <kbd>Attach Defined Schemes</kbd>
  
  Paid Insurances (Insurance (13G), Insurance (12C) and etc.,)
  <kbd>Attach Paid Insurances</kbd>
  </pre>
  
  <p><strong>Scenario:</strong></p>
  
  <p>I have headerText <code>$scope</code> variable. It contains the <code>LabelName</code>s of each section:</p>
  
  <pre><code>$scope.headerText = [{
      LabelName: 'Submitted Forms (Form (13G), Form (12C) and etc.,)'
  }, {
      LabelName: 'Planned Plans (Plan (16K), Plan (12C) and etc.,)'
  }, {
      LabelName: 'Defined Schemes (Scheme (11H), Scheme (12C) and etc.,)'
  }, {
     LabelName: 'Paid Insurances (Insurance (10G), Insurance (12C) and etc.,)'
  }];
  </code></pre>
  
  <p>This <code>LabelName</code> should be the title for each section and the same <code>LabelName</code> need to be used for the button's label text along with the text <code>Attach</code> and also need to remove the text in between the brackets. </p>
  
  <p>So in the HTML file, I tried the below code to achieve the result:</p>
  
  <pre><code>&lt;div ng-repeat="header in headerText"&gt;
      &lt;span ng-bind="header.LabelName"&gt;&lt;/span&gt;
      &lt;br /&gt;
      &lt;button&gt;{{addText.replace("{0}", header.LabelName).replace(/(\(.*\))/g, '')}}&lt;/button&gt;
      &lt;hr /&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Mean, I want to replace the content with brackets along with empty space<br>
  <strong>(Form (13G), Form (12C) and etc.,)</strong>  <br>
  from <br>
  <strong>Submitted Forms (Form (13G), Form (12C) and etc.,)</strong> <br>
  and to use that in the button's label text.</p>
  
  <p>I tried the regexp <code>.replace(/(\(.*\))/g, '')</code>, but it is not supporting.</p>
  
  <p>Is there any way to achieve this in <code>HTML</code> itself. </p>
  
  <p><a href="http://plnkr.co/edit/zOjBUtnJqdQvalNkt32J" rel="noreferrer"><code>Sample Plunker</code></a></p>