We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 14540
    • 9 Posts
    I´m trying to display four galleries on one page as well. Using &view_gallery or &gal_query_ids both works an both give equal results. Four galleries originate from 4 different documents.

    The result I dont like. Although the display is in the right place it does something I don´t want.
    I use 3 pics from a gallery from four different galleries, in total 12 pics. These are 3 seperate sets of thumbs.

    But I would like to have the different galleries seperated, now it displays image 1 of 12 in lightboxv2 and treates all images on this page as one gallery.

    Is this at all possible?

    0.5.1, 0.96, php 4.3

    Greets John
      • 7923
      • 4,213 Posts
      Yes, in the galleryPictureTpl, there is rel="lightbox[maxigallery]", change that to rel="lightbox[[+maxigallery.picture.gal_id+]]".

      And hope that the parser will parse the placeholder ok. smiley


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 14540
        • 9 Posts
        Quote from: doze at Sep 04, 2007, 08:06 AM

        Yes, in the galleryPictureTpl, there is rel="lightbox[maxigallery]", change that to rel="lightbox[[+maxigallery.picture.gal_id+]]".

        And hope that the parser will parse the placeholder ok. smiley

        Thanks for the swift reply. The parser does. Even through ditto.

        The result is the total opposite, there are no next prev links anymore, every picture stands on itself. For me this is an improvement so who is to complain wink.

        But the question still lingers, could it be done to view it as three seperate galleries... I suppose not..

        Thanks again!

        John
          • 7923
          • 4,213 Posts
          Hmm.. that should do it. Is the site online? url?

          Lightbox basicly works like this:

          1. It looks at all the link tags and and their rel attribute.
          2. It collects all pictures that have rel="lightbox[...]" in them.
          3. It looks what’s inside the brackets in lightbox[...] and organizes all pictures that have the same text to a same picture set.

          So the change that I said above should do this, it should make rel="lightbox[88]" to each picture where 88 is the gallery id for the picture. And then each picture from the same gallery should be on the same lightbox picture set. Does it do that? Is there the gallery id in the brackets for each picture?


            "He can have a lollipop any time he wants to. That's what it means to be a programmer."
            • 14540
            • 9 Posts
            Quote from: doze at Sep 05, 2007, 12:15 AM

            Hmm.. that should do it. Is the site online? url?
            Sorry for not checking sooner.

            No the site is not online, at least not reachable for others.

            Lightbox basicly works like this:

            1. It looks at all the link tags and and their rel attribute.
            2. It collects all pictures that have rel="lightbox[...]" in them.
            3. It looks what’s inside the brackets in lightbox[...] and organizes all pictures that have the same text to a same picture set.

            So the change that I said above should do this, it should make rel="lightbox[88]" to each picture where 88 is the gallery id for the picture. And then each picture from the same gallery should be on the same lightbox picture set. Does it do that? Is there the gallery id in the brackets for each picture?

            I´m not quite sure what you mean. It looks like is has the picture ID instead. It displays every picture as it was a seperate gallery.

            This is what I´ve got now
            [!Maxigallery? &view_gallery=`[+id+]` &is_target=`1` &pics_per_row=`3` &limit=`3` &disable_rightclick=`1` &display=`embedded` &embedtype=`lightboxv2` &max_pic_size=`0` &max_thumb_size=`110` &big_img_linkstyle=`popup` &thumb_use_watermark=`1` &thumb_watermark_txt=`Woodlife` &thumb_use_dropshadow=`0` &pic_use_watermark=`1` &pic_watermark_type=`image` &keep_bigimg='1' &galleryPictureTpl=`galleryPictureTpl`!]
            


            It produces this, a bit cleaned up, and deleted a lot
            <div class="thumbscontainer">
            <ul class="thumbs">
            <li><a href="/assets/galleries/24/essen_white_wash.jpg" rel="lightbox" title="">
            	<img src="/assets/galleries/24/tn_essen_white_wash.jpg" class="thumbnail" title="" alt="" />
            	</a></li>
            <li><a href="/assets/galleries/24/eiken_vloer_onbehandeld.jpg" rel="lightbox" title="">
            	 	<img src="/assets/galleries/24/tn_eiken_vloer_onbehandeld.jpg" class="thumbnail" title="" alt="" />
            	</a></li>
            </ul></div>


            galleryPictureTpl is totaly original except for your suggested change
            [+maxigallery.embedtype:is=`smoothgallery`:then=` 
            	<div class="imageElement">
            	<h3>[+maxigallery.picture.title:htmlent+]</h3>
            	<p>[+maxigallery.picture.descr:htmlent+]</p>
            	<a href="[+maxigallery.picture_link_url+]" title="[+maxigallery.strings.click_to_zoom+]" class="open"></a>
            	<img src="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" class="full" />
            	<img src="[(base_url)][+maxigallery.path_to_gal+]tn_[+maxigallery.picture.filename+]" class="thumbnail" />
            	</div>
            `+]
            
            [+maxigallery.embedtype:isnot=`smoothgallery`:then=`
             
            <li>
            [+maxigallery.embedtype:is=`slidebox`:then=` 
            
            	<a href="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" rel="lightbox_[+maxigallery.path_to_gal+]gallery">
            
            `+]
            
            [+maxigallery.embedtype:is=`lightboxv2`:then=` 
            
            	<a href="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" rel="lightbox[[+maxigallery.picture.gal_id+]]" title="[+maxigallery.picture.title:htmlent+] - [+maxigallery.picture.descr:htmlent+]">
            
            `+]
            
            [+maxigallery.embedtype:is=`slimbox`:then=` 
            
            	<a href="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" rel="lightbox[maxigallery]" title="[+maxigallery.picture.title:htmlent+] - [+maxigallery.picture.descr:htmlent+]">
            
            `+]
            
            [+maxigallery.embedtype:is=`popup`:then=` 
            
            	<a href="javascript:void(0);" onClick="javascript:openWindow('[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]','[+maxigallery.picture.title:htmlent+]',[+maxigallery.picture_height_normal+],[+maxigallery.picture_width_normal+],'gallery');">
            
            `+]
            
            [+maxigallery.embedtype:is=`external`:then=` 
            
            	<a href="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" rel="external">
            
            `+]
            
            [+maxigallery.embedtype:is=``:then=`
            	
            	<a href="[+maxigallery.picture_link_url+]">
            
            `+]
            	
            	 	<img src="[(base_url)][+maxigallery.path_to_gal+]tn_[+maxigallery.picture.filename+]" class="thumbnail" title="[+maxigallery.picture.title:htmlent+] [+maxigallery.strings.click_to_zoom+]" alt="[+maxigallery.picture.title:htmlent+] [+maxigallery.strings.click_to_zoom+]" />
            	
            	</a>
            	[+maxigallery.picture.title:isnot=``:then=`
            		<p style="width: [+maxigallery.picture_width_thumb+]px;">
            		[+maxigallery.picture.title:htmlent+]
            		</p>
            	`+]
            </li>
            `+]


            If you need more information you probably have to tell where to get it tongue
              • 7923
              • 4,213 Posts
              Well, it seems that the rel="lightbox[[+maxigallery.picture.gal_id+]]" is not parsed correctly. Try replacing:

              lightbox[[+maxigallery.picture.gal_id+]]

              with

              lightbox[test_[+maxigallery.picture.gal_id+]_test]

              in the galleryPictureTpl. That could help.


                "He can have a lollipop any time he wants to. That's what it means to be a programmer."
                • 14540
                • 9 Posts
                Quote from: doze at Sep 08, 2007, 11:50 AM

                lightbox[test_[+maxigallery.picture.gal_id+]_test]

                in the galleryPictureTpl. That could help.

                That’s it! Works like a charm.

                Thanks very much for the help.

                John

                I forgot to ask, but why does this work? I mean, ’test_.._test’ is definitly not something I could have come up with.

                  • 7923
                  • 4,213 Posts
                  Quote from: JohnO at Sep 13, 2007, 03:47 AM

                  I forgot to ask, but why does this work? I mean, ’test_.._test’ is definitly not something I could have come up with.

                  Just added the "test" string there, so that the parser wouldn’t choke on the [[+maxigallery.picture.gal_id+]] syntax.

                  You can for example just put lightbox[foo[+maxigallery.picture.gal_id+]bar]


                    "He can have a lollipop any time he wants to. That's what it means to be a programmer."