I am using jsrender
, everything is working in Chrome, however in Firefox it`s not working.
If I try to get $('#theTmpl').html() in console (using Firefox), its coming " ". But in Chrome works perfectly.
Chrome:
Firefox:
Code:
<script id="theTmpl" type="text/x-jsrender" data-jsv-tmpl="jsvTmpl">
<div>
{{if TotalNumberOfResults == 0 }}
<h3>
No Results
</h3>
</div><div>
{{else}}
<h3 id="resultFoundText" style="display:none">
Showing [[numberone]] of [[numbertwo]] matching [[searchtext]] :
</h3>
{{/if}}
</div><div class="search-result-row">
{{for Results}}
<h4>
{{for Fields}}
{{if Key == 'item_indexed_link_t'}}
<a href="{{:Value}}" class="link-text">
{{/if}}
{{/for}}
{{for Fields}}
{{if Key == 'title_t'}}
{{:Value}}
{{/if}}
{{/for}}
{{for Fields}}
{{if Key == 'item_indexed_link_t'}}
</a>
{{/if}}
{{/for}}
{{for Fields}}
{{if Key == '_templatename'}}
<span class="category">{{:Value}}</span>
{{/if}}
{{/for}}
</h4>
{{for Fields}}
{{if Key == 'description_t'}}
<p>{{:Value}}</p>
{{/if}}
{{/for}}
{{/for}}
</div><div id="loadMoreResult">
{{if TotalNumberOfResults != 0 }}
<a class="medtouch-btn danger" onclick="FillSearch(false, null, true)">Load More Result</a>
{{/if}}
</div></script>