We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 38669
    • 51 Posts
    Hey everyone,

    Client wants a product page with multiple products that is a shop layout, but isn't actually a shop. I'll use a few DIVs and classes to get it styled right.

    <div class="shopitem">
        <div class="shopitemimage"><img src="images/MainImages/Pan_26.jpg"/></div>
        <div class="shopitemprice">$21.00</div>
        <div class="shopitemdescription">Steel Pan 2 person (26cm)</div>
    </div>


    No problem so far, just repeat that down the page for each item

    For those of use fluent in HTML, adding a new item is a snap - do it in the HTML view.

    But to hand it over and have someone do it in WYSIWYG is fraught with peril. I was thinking of creating some chunks that have the elements in it so they would do this in WYSIWYG

    [[$item]]
        [[$itemimage]](inserted image)
        [[$itemprice]]$21
        [[$itemdescription]]Blah
    [[$enditem]]


    Kind of like XML.

    Doesn't seem like a bad idea, but perhaps someone else has done this and can either offer a better way or confirm this as a good way.

    Thanks in advance for any thoughts.
      • 28120
      • 380 Posts
      I tend to make each product a MODX Resource and then generate the listing page with getresources.

      It means the user can easily edit each product/resoure with a combination of the content field plus a few template variables. Also allows draggingg up and down the tree to change sequence.
        • 38669
        • 51 Posts
        Hmmm...yes, I can see that is a better idea. Also consistent with the way they do their blog.

        Many thanks...where's the +1 button? smiley