We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 47432
    • 48 Posts
    there under no other resource, they are in first level
      • 4172
      • 5,888 Posts
      I see.
      Then try
      &parents=`0`
        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!
        • 47432
        • 48 Posts
        It works!!!!
        I had try the 0, but before having the @inline
        well, i will continue with the pathfinder and the works section tomorrow

        thanks to you and Suzan i have learned a lot today smiley))
          • 47432
          • 48 Posts
          Well now i'm trying to display the works section with getresources, but as each item open in the same page and not in another page, i don't know how to do it
          so i tried to have the "work single" in a child resource from work, have for it a new template, call this resource in the page with get resource (same way that the others winth the @inline, and with the work resource ID as parent.
          But as the work resource is already called by getresource in my onepage template, i had a fatal error, and so read that it create an infinite loop :-(
          So i really don't know how to do that

          For the quotes between sections, i tried with migx, but i make a mess, so finally i decide to have it with simple tv, adding 3 categories quote1, 2, 3
            • 4172
            • 5,888 Posts
            might be the MODX - parser gets a bit confused with
            this as outside - call
            [[getResources? &parents=`[[*id]]` &includeContent=`1` &tpl=`@INLINE [[+content]]`]]


            and inside the content of works

            [[getResources? &parents=`yourWorksID` &includeContent=`1` &tpl=`@INLINE [[+content]]`]]


            try to use real chunks for the tpls, or at least for the inner getResources-call

            [[getResources? &parents=`yourWorksID` &includeContent=`1` &tpl=`theWorksTplChunk`]]


            Then you can format the inner tpl-chunk (theWorksTplChunk) as you like.
              -------------------------------

              you can buy me a beer, if you like MIGX

              http://webcmsolutions.de/migx.html

              Thanks!
              • 47432
              • 48 Posts
              Thank you Bruno,
              i will study that tomorrow, now it's time to go out for me smiley

              i'm happy, just succeed having the team section with migx...without help and without errors smiley))
                • 47432
                • 48 Posts
                Hi,
                i don't know if i understood very well, but it don't work when i click on w-view more the single work don't appear

                that is what i've done:

                i took the code from the hidden single work, and had in a chunck: singleWorlTpl , then i create a template singleWork, and had this chunk in the template
                i create a new resource work_single (child of works, and hidden from menu) with the template singleWork

                then i replace the code of single work (in the work resource) by [[getResources? &parents=`4` &includeContent=`1` &tpl=`singleWorkTpl`]]
                [[getResources? &parents=`4` &includeContent=`1` &tpl=`singleWorkTpl`]]


                Other problem, on my team section, i thought yesterday it was allright, but there was a mess in the second row, i looked at the code, and at is formatted as columns, each two member are in a div class="row"
                so i rebuild the tv and the chunk tpl like that,

                [
                {"caption":"Team Member", "fields": [
                   {"field":"member_name1","caption":"Name1"},
                   {"field":"member_role1","caption":"Role1"},
                   {"field":"member_text1","caption":"Text1"},
                   {"field":"member_image1","caption":"Image1","inputTVtype":"image"}
                {"field":"member_name2","caption":"Name2"},
                   {"field":"member_role2","caption":"Role2"},
                   {"field":"member_text2","caption":"Text2"},
                   {"field":"member_image2","caption":"Image2","inputTVtype":"image"}
                ]}
                ]


                [
                {"header": "Name1", "width": "200", "sortable": "true", "dataIndex": "member_name1"},
                {"header": "Role1", "width": "200", "sortable": "false", "dataIndex": "member_role1"},
                {"header": "Text1", "width": "200", "sortable": "false", "dataIndex": "member_text1"},
                {"header": "Image1", "width": "200", "sortable": "false", "dataIndex": "member_image1","renderer":"this.renderImage"}
                {"header": "Name2", "width": "200", "sortable": "true", "dataIndex": "member_name2"},
                {"header": "Role2", "width": "200", "sortable": "false", "dataIndex": "member_role2"},
                {"header": "Text2", "width": "200", "sortable": "false", "dataIndex": "member_text2"},
                {"header": "Image2", "width": "200", "sortable": "false", "dataIndex": "member_image2","renderer":"this.renderImage"}
                
                ]


                and the tplchunk

                <div class="w-row">
                <div class="w-col w-col-6"><img alt="535f8441c078d64b690005e0_4217144639_83499060db_n.jpg" class="team-img" data-ix="appear-left-on-scroll" src="[[+member_image1]]" />
                <div class="overlay">
                <h3 class="h3-team">[[+member_name1]]</h3>
                
                <h4 class="work-title">[[+member_role1]]</h4>
                
                <p class="p-team">[[+member_text1]]</p>
                <a class="w-inline-block" href="#"><img alt="535f8c42301137b76f000795_facebook.png" class="social-img" src="assets/templates/seen/images/facebook.png" /> </a> <a class="w-inline-block" href="#"> <img alt="535f8dd5af0f48b96f0006c1_twitter.png" class="social-img" src="assets/templates/seen/images/twitter.png" /> </a> <a class="w-inline-block" href="#"> <img alt="535f8de5301137b76f0007aa_linkedin.png" class="social-img" src="assets/templates/seen/images/linkedin.png" /> </a></div>
                </div>
                
                <div class="w-col w-col-6"><img alt="535f8441c078d64b690005e0_4217144639_83499060db_n.jpg" class="team-img" data-ix="appear-left-on-scroll" src="[[+member_image2]]" />
                <div class="overlay">
                <h3 class="h3-team">[[+member_name2]]</h3>
                
                <h4 class="work-title">[[+member_role2]]</h4>
                
                <p class="p-team">[[+member_text2]]</p>
                <a class="w-inline-block" href="#"><img alt="535f8c42301137b76f000795_facebook.png" class="social-img" src="assets/templates/seen/images/facebook.png" /> </a> <a class="w-inline-block" href="#"> <img alt="535f8dd5af0f48b96f0006c1_twitter.png" class="social-img" src="assets/templates/seen/images/twitter.png" /> </a> <a class="w-inline-block" href="#"> <img alt="535f8de5301137b76f0007aa_linkedin.png" class="social-img" src="assets/templates/seen/images/linkedin.png" /> </a></div>
                </div>
                
                </div>


                I think it's correct, but now, when i go to the resource and try to add a new item, the window open but i have , nothing in it, i tried to delete the tv and rebuild it, but it don't work
                i already notice this problem when i was building the slider and modify the tv to add the image, but after finally it comes back normal
                so i think there's a problem when we make a modification to a migx tv, but i don't know how to fix it

                I hope i don't bother you to much with all that questions, i begin modx less than 2 weeks ago, and as i like to build sophisticated designs, i go the tricky way, even if i don't always need it (for the one page nav, i think it would be easier to have it manually than having each section in a resource etc...), but i believe that beginning with this exercise i will be able to do what i want when i begin with real production smiley
                  • 4172
                  • 5,888 Posts
                  you are missing a , in each of both json-strings

                  [
                  {"caption":"Team Member", "fields": [
                     {"field":"member_name1","caption":"Name1"},
                     {"field":"member_role1","caption":"Role1"},
                     {"field":"member_text1","caption":"Text1"},
                     {"field":"member_image1","caption":"Image1","inputTVtype":"image"},
                     {"field":"member_name2","caption":"Name2"},
                     {"field":"member_role2","caption":"Role2"},
                     {"field":"member_text2","caption":"Text2"},
                     {"field":"member_image2","caption":"Image2","inputTVtype":"image"}
                  ]}
                  ]
                  


                  [
                  {"header": "Name1", "width": "200", "sortable": "true", "dataIndex": "member_name1"},
                  {"header": "Role1", "width": "200", "sortable": "false", "dataIndex": "member_role1"},
                  {"header": "Text1", "width": "200", "sortable": "false", "dataIndex": "member_text1"},
                  {"header": "Image1", "width": "200", "sortable": "false", "dataIndex": "member_image1","renderer":"this.renderImage"},
                  {"header": "Name2", "width": "200", "sortable": "true", "dataIndex": "member_name2"},
                  {"header": "Role2", "width": "200", "sortable": "false", "dataIndex": "member_role2"},
                  {"header": "Text2", "width": "200", "sortable": "false", "dataIndex": "member_text2"},
                  {"header": "Image2", "width": "200", "sortable": "false", "dataIndex": "member_image2","renderer":"this.renderImage"}
                   
                  ]
                  


                  but I think you don't need the second ones.
                  I'm sure there is a way to get it done without the second set of fields.
                    -------------------------------

                    you can buy me a beer, if you like MIGX

                    http://webcmsolutions.de/migx.html

                    Thanks!
                    • 47432
                    • 48 Posts
                    i forgot 2 commas :-( now everything works, and i've also made the pricing tables with migx, and going to make the services items

                    do you see a solution for the works ?
                    if i don't find i will abandon the idea to have all each section in a different resource to use wayfinder, and will keep the manual menu
                    but if find the solution it would be perfect
                      • 47432
                      • 48 Posts
                      Now i'm doing the services item, but when i go to the resource and look at the variables, i only have the name of the tv services_item and nothing more
                      i have rebuilt the TV several times, verify every comma, and i cannot find my error (and the pricing table was more complicated but i succeed)

                      here is the code:
                      [
                      {"caption":"Services Items", "fields": [
                         {"field":"services_icon","caption":"Icon","inputTVtype":"image" },
                         {"field":"services_title","caption":"Title"},
                      {"field":"services_text","caption":"Text"},
                         
                      ]}
                      ]


                      [
                      {"header": "Icon", "width": "200", "sortable": "true", "dataIndex": "item_icon", "renderer":"this.renderImage"},
                      {"header": "Title", "width": "200", "sortable": "false", "dataIndex": "item_title"},
                      {"header": "Text", "width": "200", "sortable": "false", "dataIndex": "item_text"},
                      
                      
                      
                      ]