We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 19002
    • 32 Posts
    Hey folks,

    I want to use maxigallery to manage the upload and tagging of images on the backend of a site I’m building. I’m already using ’managermanager’ and ’mg_backend_manager’ to embed maxigallery picture manager in the manager interface. I have a sweet, simple jquery image rotator that I’d like to use, but I’m having trouble pulling the image gallery into it.

    How can I target the gallery (should I be using tv’s?), or should I be trying to edit the actual maxigallery templates (if this is the case, how do I start?)?

    thanks.

    Craig
      • 7923
      • 4,213 Posts
      Quote from: mediassassin at Apr 22, 2009, 05:48 PM

      How can I target the gallery
      What do you mean by this..? Target the images of a gallery with your jquery script or what? There are css classes in the elements of the default templates what you can choose to use..

      Take for example this maxigallery output:
      <div class="thumbscontainer">
      <ul class="thumbs">
      	<li>
      		<a href="/assets/galleries/1/1.jpg" rel="lightbox[maxigallery]" title="title - description">
      		 	<img src="/assets/galleries/1/tn_1.jpg" class="thumbnail" title="title  » Click to zoom ->" alt="title  » Click to zoom ->" />
      		</a>
      		<p style="width: 130px;">
      			title
      		</p>
      	</li>
      </ul>
      </div>
      


      To select the li elements for example with jQuery, you would do something like: $(".thumbs > li")

      Quote from: mediassassin at Apr 22, 2009, 05:48 PM

      or should I be trying to edit the actual maxigallery templates (if this is the case, how do I start?)?
      The templates are meant to be edited. They are just default templates. You can do a chunk in MODx with the contents of the default template and modify it how ever you like. Then in your snippet call, define that chunk with the appropriate template parameter.


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 19002
        • 32 Posts
        OK following the example on the wiki, I have the gallery pulling and displaying the way I want. But for some reason it is only pulling the second image from the gallery folder I specified, is this because it is only pulling the most recent?

        here is the snippet call I am using:
        [!MaxiGallery?  &pictureTpl=`FeatureRotator` &display=`pictureview` &view_gallery=`29` !]


        and here is the chunk:
        <div id="s3slider">
        <!--[if IE 6]>
        <img" id="mask" src=[(base_url)]assets/templates/wilcorp/img/'1x1.png' style='filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src="[(base_url)]assets/templates/wilcorp/img/mask.png", sizingMethod="image");' />
        <![endif]-->
        <!--[if IE 7]><!-->
        <img id="mask" src="[(base_url)]assets/templates/wilcorp/img/mask.png" alt="" />
        <!--<![endif]-->
        <ul id="s3sliderContent">
        <li class="s3sliderImage">
        <img id="maxImage" src="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" height="465px" width="709px" alt="[+maxigallery.picture.title:htmlent+]" />
        <span>
        <h4 id="maxTitle" >[+maxigallery.picture.title:htmlent+]</h4>
        <p id="maxDescr">[+maxigallery.picture.descr:htmlent+]</p>
        </span>
        </li>
        </ul>
        </div> 


        Is there a way to make the img tag a placeholder to pull the images in? I’m using a jquery slideshow that I like, and just need to figure out how to pull the specified gallery images into a place holder (similar to how wayfinder will just keep inserting "row" templates.

        thanks.

        C
          • 7923
          • 4,213 Posts
          If you want all the images from the gallery, do not use the pictureview display type.

          You can do a custom galleryPictureTpl to list the normal images and not thumbnails by removing the "tn_" prefix from the picture file name in the template.


            "He can have a lollipop any time he wants to. That's what it means to be a programmer."
            • 19002
            • 32 Posts
            Thanks Doze, I actually found another post from someone who was doing pretty much the same thing as me, and just copied their code. I would have used smoothgallery but I have jquery on my page and mootools killed it.