We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33980
    • 5 Posts
    Hi !
    please can someone help me ?
    i want to display a thumb image of an article's image when i use ditto on
    my web page.
    i don't know the way to do it.
    is it any solution ready to use?
    thank by advance
      "In quietness and trust is your strength" Isaiah 30:15
      • 19369
      • 1,098 Posts
      Hello,

      If you want to crop the image, like a square for example, you can use advthumbs snippet or phpThumb. Below is an example using advthumbs.

      <img src="[[advthumbs? &filename=`[+myArticleImageTvHere+]` &newxsize=`200` &newysize=`200` &method=`resizecrop`]]" alt="[+pagetitle+]" />
        • 33980
        • 5 Posts
        Thank for this answer microcipcip
        the issue is that, i don't know how to use an image tv to be displayed in a ditto call
        can you help me to perform that
        thk
          "In quietness and trust is your strength" Isaiah 30:15
          • 19369
          • 1,098 Posts
          Can you show me your Ditto call and the Ditto template code? Use the code button here in the forum otherwise it will not show up.
            • 36404
            • 307 Posts
            hi,

            if i may, actually, in a ditto call you usually use a chunk as a template to display the result
            &tpl=`somethingTpl`
            in the chunk you can easily use a snippet to get any kind of tv output you need

            have swing
              réfléchir avant d'agir
              • 33980
              • 5 Posts
              Thk guy what i have done is this
              i have created a new snipet

              the apercu_publication_tpl ditto template is:
              <div class="post">
              	<h3><a href="[~[+id+]~]">[+pagetitle+]</a></h3>
                      </p>
              	<img src="[[advthumbs? &filename=`[+thumbIMG+]` &newxsize=`150` &newysize=`150` &method=`resizecrop`]]alt="[*pagetitle*]" />
              	<small>Publié le: [+date+]</small> 
              
              	[+introtext+]
                      </p>
              	<a class="more" href="[+url+]">Lire la suite...</a>
              </div>
              


              my ditto call is:
              [[Ditto? &parents=`16` &display=`4` &removeChunk=`Comments` &tpl=`apercu_publication_tpl` &paginate=`1` &extenders=`summary,dateFilter` &paginateAlwaysShowLinks=`0` &tagData=`` &orderBy=`createdon DESC` &lang=`french`]]
              


              but the image is not displaying. When i remove the "advthumbs" snippet call, the image can be render but [ed. note: african modxor last edited this post 14 years, 6 months ago.]
                "In quietness and trust is your strength" Isaiah 30:15