 <p>Do not use functions in templates when you can avoid this.</p> <pre><code>&lt;select ng-model="template"&gt; &lt;option value="test.html"&gt;first&lt;/option&gt; &lt;option value="test2.html"&gt;second&lt;/option&gt; &lt;/select&gt; &lt;div ng-include="template"&gt;&lt;/div&gt; </code></pre> <p><a href="http://plnkr.co/edit/osB9UiSzvF4IoqkizcOP?p=preview" rel="nofollow">http://plnkr.co/edit/osB9UiSzvF4IoqkizcOP?p=preview</a></p>