title: How can i use if then else in hbs backbone template file, i m using handelsbar for template
body: <p>i want to use if then else in hbs file, if <code>{{NumLikes}}</code> is greater than <code>0</code> then 1st image else 2nd image, so how i can use if then else in hbs template file using backbone.js.
  I am using handelsbar for template.</p>
  
  <pre><code>&lt;div&gt;
          &lt; div class="comm-tab-row"&gt;
              &lt;div class="post-left-panel"&gt;
                  &lt;div class="post-image-container"&gt;
                   &lt;img src="{{UserImageURL}}" alt="" class="post-image"  /&gt;&lt;/br&gt;     
                  &lt;% if ({{NumLikes}} = 0) { %&gt;
                      &lt;img src="images/myCommunity/like@2x.png" width="20" height="19" id="like-btn" name = "like-Button" &gt;               
                  &lt;% } else { %&gt;
                      &lt;img src="images/myCommunity/liked@2x.png" width="20" height="19" id="like-btn" name = "like-Button" &gt;
                  &lt;%  } %&gt;            
                  ({{NumLikes}})          
                  &lt;/div&gt;
              &lt;/div&gt;      
              &lt;div class="post-body"&gt;
                  &lt;h5 class="comm-tab-heading"&gt;
                      &lt;span class="navigate-screen" id="{{Id}}" style="text-decoration:underline;"&gt;
                          {{UserName}}
                      &lt;/span&gt;
                      &lt;span&gt;
                           - &amp;nbsp;
                      &lt;/span&gt;
                      &lt;span&gt;
                         {{format_date Time ""}}
                      &lt;/span&gt;
                  &lt;/h5&gt;
                  {{Message}}
                  &lt;/div&gt;
                  &lt;div class="comm-right-panel"&gt;
                  &lt;a href="javascript:void(0);" class="btn-follow" name = "follow-button"&gt;FOLLOW&lt;/a&gt;
                      &lt;a href="javascript:void(0);" class="btn-comment" name = "comment-button"&gt;{{NumComments}} - COMMENT&lt;/a&gt;
              &lt;/div&gt;  
              &lt;/div&gt;
  
          &lt;/div&gt;
      &lt;/div&gt;
  </code></pre>