Jump to content

How to approach this feat in Processwire


qtguru

Recommended Posts

Progress is going on well, as usual my choice for Development:

 

TemplateEngineFactory + Twig 

image.thumb.png.94361163f77af760c26022fdef152448.pngimage.thumb.png.8cd3e17fedcc74b6d1953aa4d2fec4d8.png

      {% for article in articles %}
                {% set divisor = 10 %}
                {% if loop.index0 == 0 %}
                    <div class="flex-center flex-col aa-list">
                        <h4>Articles</h4>
                        <ul>
                {% else %}
                            <li>
                                <a href="{{ article.url }}" target="_blank"
                                >{{ article.title }}</a
                                >
                                <span> {{ article.publishedStr }}</span>
                            </li>

                        {% endif %}
                        {% if loop.index % (divisor + 1) == 0 %}
                            </ul>
                        </div>
                    <div class="flex-center flex-col aa-list">
                        <h4>Articles</h4>
                        <ul>
                            {% elseif loop.last %}
                                </ul>
                                </div>

                        {% endif %}
                        {% endfor %}

 

  • Like 3
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...