attachment
The attachment
object has the following attributes:
listing.attachments
Returns all attachments of that listing.
Input
<ul>
{% for attachment in listing.attachments %}
<li>{{ attachment.name }}</li>
{% endfor %}
</ul>
Output
<ul>
<li>burger.jpg</li>
<li>drum.pdf</li>
</ul>
attachment.name
Returns attachment’s name with extension as type of string.
Input
<h1>{{ attachment.name }}</h1>
Output
<h1>burger.jpg</h1>
attachment.file_size
Returns attachment’s file_size.
attachment.url
Returns attachment’s url (Amazon S3 attachment url).
Input
<p>{{ attachment.url }}</p>
Output
<a href="https://s-staging-yoolk-assets.s3.amazonaws.com/kh/attachments/kh54997/burger.jpg">burger.jpg</a>