We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 1526
    • 72 Posts
    as for instructions, [+maxigallery.index_url+] should point to "Url to gallery overview index" in the picture template.
    But with &display=`pictureview` the link sends me to the first slide.
    When accessing the gallery, my client doesn't want to land to the thumnails, but directly to the first slide, and I did this with &display=`pictureview`.
    But he also wishes a link from the slide to the overview index (thumbnails). Is there any way to do it?
    Thank you
      MODx evo 1.5~1.6 ✪ Apache v 2.2.22 ✪ PHP v 5.3.10 ✪ MySQL v 5.1.61
      <°'iiii);
      • 22427
      • 793 Posts
      In one of my Maxigalleries, when a single slide is displayed the URL of it is something like
      http://www.example.com/galleries/gallery1.html?pic=1111&from_id=22
      Now I just have this link in the pictureTpl:
      <a href="[~[*id*]~]">Overview</a>
      Here "[~[*id*]~]" resolves to "http://www.example.com/galleries/gallery1.html" (without the parameters pic and from_id) which is the page with the thumbnails.
        • 1526
        • 72 Posts
        Thank you, that didn't work. It just goes to the first slide (even with the url without the ?pic part). It must be &display=`pictureview`.
        OR with &display=`normal` there is any way to jump the thumbnail page and land on the first image
        OR with &display=`pictureview` I havo to find a way to create a thumbnail page. [ed. note: andrearicci last edited this post 14 years, 6 months ago.]
          MODx evo 1.5~1.6 ✪ Apache v 2.2.22 ✪ PHP v 5.3.10 ✪ MySQL v 5.1.61
          <°'iiii);
          • 1526
          • 72 Posts
          So, I'm keeping the &display=`pictureview` and trying to change the link to index [+maxigallery.index_url+] in the template with a snippet.
          I found this code in maxigallery.php:
          //build back to index link
          if($_REQUEST['from_id']){
          	$back_to_index = $modx->makeUrl($_REQUEST['from_id'], '', 'page='.$page);
          }else if($mg->mgconfig['is_target']==true && $_REQUEST['gal_id']){
          	$back_to_index = $modx->makeUrl($_REQUEST['gal_id'], '', 'page='.$page);
          }else{
          	$back_to_index = $modx->makeUrl($modx->documentIdentifier, '', 'page='.$page);
          }
          and trying to use the makeUrl functions. Unlikylly if I use
          $back_to_index = $modx->makeUrl($_REQUEST['from_id'], '', 'page='.$page);
          or
          $back_to_index = $modx->makeUrl($_REQUEST['gal_id'], '', 'page='.$page);
          I get the parser error:
          « `` is not numeric and may not be passed to makeUrl() »

          Any Help? Thank you
            MODx evo 1.5~1.6 ✪ Apache v 2.2.22 ✪ PHP v 5.3.10 ✪ MySQL v 5.1.61
            <°'iiii);