Hi all, hoping you can help. I posted yesterday about this but my post got removed due to the spambot. No idea why but it might be cos I included links.
So, Im developing a gitub pages site and I need help about why my simple gallery images are printing twice.
Code
<!-- gallery html from https://dmnfarrell.github.io/software/jekyll-galleries -->
<div class="thumb-wrap"><div id="image-gallery">
{% assign sorted = site.static_files | sort: 'date' | reverse %}
{% for file in sorted %}
{% if file.path contains include.folder %}
{% if file.extname == '.jpg' or file.extname == '.png' %}
{% assign filenameparts = file.path | split: "/" %}
{% assign filename = filenameparts | last | replace: file.extname " " %}
<div class="box">
<a href="{{site.baseurl}}{{ site.imagesurl }}{{ include.folder }}/{{ file.name }}" title="{{ filename }}"><img src="{{site.baseurl}}{{ site.thumbsurl }}{{ include.folder }}/{{ file.name }}" alt="{{ filename }}" class="img-gallery" /> </a>
</div>
{% endif %}
{% endif %}
{% endfor %}
</div></div>
Im declaring imagesurl and thumbsurl in the config yaml.
imagesurl: "/assets/galleries/"
thumbsurl: "/assets/thumbs/"
The method Im using is from Damien Farrell. I wont link to his blogpost in case this post is removed again due to spambot. I can share my repo and the site url but wont in case spambot