Assuming I have a list of tags: iFix_6.3
, iFix_7.0
, iFix_7.1
, iFix_8.0
, announcement
, and so on... and I want to run an operation only on certain several tags. How can I check for these multiple values?
There is contains
, but I'm looking for the opposite of it and for multiple values...
Here is an example where I actually filter out all posts that contain the iFix_6.3
tag, thus display all other posts. This actually does not work yet... plus needs to be extended to work for multiple tags.
// posts with iFix_xxx tag should be filtered from the main posts view.
{% assign postUpdates = site.posts | where_exp:"item", "item.tags != 'iFix_6.3'" %}
{% for post in postUpdates limit:10 %}
<div class="postItem inline">
<p class="postDate">{% if post.pinned %}<span class="glyphicon glyphicon-pushpin"></span>{% endif %}{{post.date | date: '%B %d, %Y'}}</p>
<p class="postTitle"><a href="{{site.baseurl}}{{post.url}}">{{post.title}}</a></p>
</div>
{% endfor %}