Detect last plugin in a placeholder
Is there a way to detect the last (o开发者_开发知识库r first) plugin that has been placed inside a placeholder?
I want to add a class="last" to my plugin template in case of the last plugin.
Give this a try:
{% if plugin.last %} This is the last plugin for current placeholder {% endif %}
(plugin.first should also work)
精彩评论