Wrap various field templates in {{##if}} guards.
authorMike Taylor <mike@indexdata.com>
Wed, 27 Nov 2013 16:39:31 +0000 (16:39 +0000)
committerMike Taylor <mike@indexdata.com>
Wed, 27 Nov 2013 16:39:31 +0000 (16:39 +0000)
Use {{#link}} helper for md-electronic-url.

examples/htdocs/mike.html

index 02bf56d..6e15b2e 100644 (file)
            {{/if}}
          </td>
        </tr>
            {{/if}}
          </td>
        </tr>
+       {{#if md-date}}
        <tr>
          <th>Date</th>
          <td>{{md-date}}</td>
        </tr>
        <tr>
          <th>Date</th>
          <td>{{md-date}}</td>
        </tr>
+       {{/if}}
+       {{#if md-author}}
        <tr>
          <th>Author</th>
          <td>{{md-author}}</td>
        </tr>
        <tr>
          <th>Author</th>
          <td>{{md-author}}</td>
        </tr>
+       {{/if}}
+       {{#if md-electronic-url}}
        <tr>
          <th>URL</th>
        <tr>
          <th>URL</th>
-         <td>{{md-electronic-url}}</td>
+         <td>{{#link md-electronic-url}}{{/link}}</td>
        </tr>
        </tr>
+       {{/if}}
        <tr>
          <th>Subject</th>
          <td>{{md-subject}}</td>
        <tr>
          <th>Subject</th>
          <td>{{md-subject}}</td>