We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 39839
    • 14 Posts
    Hello all.

    I want get two resources together for my list of products, example:

    Set of resource in MODX Revolution

    **Resources parents
    |-- resources 01
    |-- resources 02
    |-- resources 03
    |-- ...
    |-- ...
    |-- resources N-1
    |-- resources N


    Output HTML in the page web.

    <li>
    <div> resources 01 </div>
    <div> resources 02 </div>
    </li>

    <li>
    <div> resources 03 </div>
    <div> resources 04 </div>
    </li>
    ...
    ...
    ...
    <li>
    <div> resources N-1 </div>
    <div> resources N </div>
    </li>





    I try by filters but that can't.

    Thank you all
    Luis. [ed. note: nolberto last edited this post 12 years, 11 months ago.]
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Is that particular HTML structure absolutely necessary?
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 42046
        • 436 Posts
        Could you use &tpl_n2=`secondTpl` to format every second resource differently?

        firstTpl:

        <li>
        <div> resources 01 </div>
        


        secondTpl:

        <div> resources 02 </div>
        </li>


        tpl_nN: Name of a chunk serving as resource template for every Nth resource, for example &tpl_n4=`tpl4th` would apply to any item divisible by 4
          • 39839
          • 14 Posts
          Quote from: sottwell at Oct 12, 2013, 11:57 AM
          Is that particular HTML structure absolutely necessary?

          Hello Stowell.

          Yes, it is necessary because by design, I send a example image.
            • 39839
            • 14 Posts
            Quote from: absent42 at Oct 12, 2013, 12:09 PM
            Could you use &tpl_n2=`secondTpl` to format every second resource differently?

            firstTpl:

            <li>
            <div> resources 01 </div>
            


            secondTpl:

            <div> resources 02 </div>
            </li>


            tpl_nN: Name of a chunk serving as resource template for every Nth resource, for example &tpl_n4=`tpl4th` would apply to any item divisible by 4


            Hello Dan.

            The format of the second ressource is same of the first resource, I send a example image
              • 42046
              • 436 Posts
              I don't really understand what in that image requires 2 getResources templates. What I see is 8 identical resource templates. Can't you rework the html so each resource is contained in it's own list item?
                • 28042 ☆ A M B ☆
                • 24,524 Posts
                Indeed. It doesn't even need to be a list. Simply use CSS to float and size the divs in such a way that the desired number of divs at a time fit in the space.
                  Studying MODX in the desert - http://sottwell.com
                  Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                  Join the Slack Community - http://modx.org
                  • 39839
                  • 14 Posts
                  Quote from: sottwell at Oct 12, 2013, 09:05 PM
                  Indeed. It doesn't even need to be a list. Simply use CSS to float and size the divs in such a way that the desired number of divs at a time fit in the space.

                  Hello Sottwell.

                  Thank you for yours response, I have explore the database and I can find the answer.

                  Now, my problem is how move my modx localhost to hosting, I have try but always I get a message of error.
                    • 39839
                    • 14 Posts
                    Quote from: absent42 at Oct 12, 2013, 02:04 PM
                    I don't really understand what in that image requires 2 getResources templates. What I see is 8 identical resource templates. Can't you rework the html so each resource is contained in it's own list item?

                    Hello Dan.

                    Thank you for yours response