We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16899
    • 284 Posts
    Hi All

    I have a situation where i need to get the first image of an image gallery generated by MIGX plugin. The think is that i need to resize the image using the phpyhumbof. I can i do that? Any sugestion?
    I tried to do something like this, but obviously didn´t work!! sad

    [[!getImageList?:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0` &limit=`1` &tvname=`gallery` &tpl=`projectsTpl` &docid=`[[+id]]`]]


    Many thanks in advance
    [ed. note: legues last edited this post 14 years, 4 months ago.]
      • 4172
      • 5,888 Posts
      you need to do this on your image-placeholder in your projectsTpl, lets say its called 'image' :

      [[+image:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0`]]
        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!
        • 16899
        • 284 Posts
        Hi Bruno17

        Ok, the thing is... i have a project page, with an image gallery where each image has 800px by 400px. What i want is get the first image of this gallery to the main projects page, where i show an image preview of all my projects!!!

        To do this i´m using getpage/getresources (on the main projects page) and i use this call:

        					[[!getPage? 
        					&elementClass=`modSnippet` 
        					&element=`getResources`
        					&parents=`6` 
        					&limit=`6`
        					&sortdir=`ASC`
        					&includeTVs=`1` 
        					&processTVs=`1`
        					&tpl=`projectsTpl`
        					]]


        The projectsTpl that i´m using (and need to use phpthumbof) is:

        						<!-- START ITEM -->
        						<div class="project-item">
        							<div class="project-image">
        								<a href="[[~[[+id]]]]"><img src="[[!getImageList &limit=`1` &tvname=`gallery` &tpl=`projectsTpl` &docid=`[[+id]]`]]:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0`" alt="[[+tv.main-content-title]]" class="fx7"/></a>
        							</div>
        							<div class="project-caption">
        								<h4>[[+tv.main-content-title]]</h4>
                                    				</div>
        						</div>
        						<!-- ENDS ITEM -->


        Sorry about my english and many thanks to your reply
          • 4172
          • 5,888 Posts
          what is the content of projectsTpl
            -------------------------------

            you can buy me a beer, if you like MIGX

            http://webcmsolutions.de/migx.html

            Thanks!
            • 16899
            • 284 Posts
            <!-- START ITEM -->
            <div class="project-item">
                <div class="project-image">
                    <a href="[[~[[+id]]]]"><img src="[[!getImageList? &limit=`1` &tvname=`gallery` &tpl=`projectsTpl` &docid=`[[+id]]`]]:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0`" alt="[[+tv.main-content-title]]" class="fx7"/></a>
                </div>
                <div class="project-caption">
                    <h4>[[+tv.main-content-title]]</h4>
                                </div>
            </div>
            <!-- ENDS ITEM -->
            [ed. note: legues last edited this post 14 years, 4 months ago.]
              • 4172
              • 5,888 Posts
              ???

              and you are using the same tpl for getImageList ?
                -------------------------------

                you can buy me a beer, if you like MIGX

                http://webcmsolutions.de/migx.html

                Thanks!
                • 16899
                • 284 Posts
                How can you get an image from MIGX output to another page?

                What i need is get the first image from this page http://www.panoramicinvest.co.uk/current-projects/xpto0001.html to this page http://www.panoramicinvest.co.uk/current-projects.htmls.html. The thing is my gallery it´s generateed by MIGX plugin, so i don´t know how to get the first image to the main projects page. [ed. note: legues last edited this post 14 years, 4 months ago.]
                  • 4172
                  • 5,888 Posts
                  <a href="[[~[[+id]]]]"><img src="
                  [[!getImageList? 
                  &limit=`1` 
                  &tvname=`gallery` 
                  &tpl=`imageTpl` 
                  &docid=`[[+id]]`]]" alt="[[+tv.main-content-title]]" class="fx7"/></a>
                  
                  


                  imageTpl:

                  <img src="[[+image:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0`]]" alt="[[+tv.main-content-title]]" class="fx7"/>


                    -------------------------------

                    you can buy me a beer, if you like MIGX

                    http://webcmsolutions.de/migx.html

                    Thanks!
                    • 16899
                    • 284 Posts
                    Hi Bruno

                    Thanks a lot!!! It´s working now!!!! smiley Really usefull your help! wink In the imageTpl i just had to insert this code
                    [[+image:phpthumbof=`w=280&h=280&zc=1&aoe=0&far=0`]]
                    because i´m already calling the template inside image src!! smiley

                    Thanks again!! smiley