We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29163
    • 18 Posts
    tabor.carlton Reply #1, 17 years ago
    It states in the wiki that the Ajax search (I am using it in non-Ajax mode) will:

    Search in title, description of images of maxigallery. Display the images found as search results with a link to the image in the gallery

    I don’t know if I have something incorrect in my search snippet listed on my results page:

    [!AjaxSearch? &ajaxSearch=`0` &AS_showForm=`0`!] 


    or if I am missing a parameter in my gallery. I have the page that the gallery is on searchable and published. Any ideas out there?
      Tabor Carlton // Interactive Art Director
      http://www.taborcarlton.com
      http://www.alternative-media.net
      • 5811
      • 1,717 Posts
      For a search only in maxigallery:
      [!AjaxSearch? &ajaxSearch=`0` &AS_showForm=`0` &whereSearch=`content:null|maxigallery` &tplResult=`withMaxigalleryResult`!]


      If you want a search in documents (content,tv) AND maxigallery:
      [!AjaxSearch? &ajaxSearch=`0` &AS_showForm=`0` &whereSearch=`content|tv|maxigallery` &tplResult=`withMaxigalleryResult`!]


      Notice the difference in the &whereSearch parameter wink

      With withMaxigalleryResult chunk:
      <div class="[+as.resultClass+]">
        <a class="[+as.resultLinkClass+]" href="[+as.resultLink+]" title="[+as.longtitle+]">[+as.pagetitle+]</a>
      [+as.descriptionShow:is=`1`:then=`
        <span class="[+as.descriptionClass+]">[+as.description+]</span>
      `+]
      [+as.gal_idShow:is=`1`:then=`
        <br />[!MaxiGallery? &pic_query_ids=`[+as.gal_id+]` &galleryPictureTpl=`subSearchGalleryPictureTpl`!] 
      `+]<br />
      [+as.extractShow:is=`1`:then=`
        <div class="[+as.extractClass+]"><p>[+as.extract+]</p></div>
      `+]
      [+as.breadcrumbsShow:is=`1`:then=`
        <span class="[+as.breadcrumbsClass+]">[+as.breadcrumbs+]</span>
      `+]
      </div>
      Notice the embedded Maxigallery snippet call to display the image
      [!MaxiGallery? &pic_query_ids=`[+as.gal_id+]` &galleryPictureTpl=`subSearchGalleryPictureTpl`!]
      In this example I have redefine the galleryPictureTpl template too.

      See the With Maxigallery and Jot demo (ajax mode) as example.

        • 29163
        • 18 Posts
        tabor.carlton Reply #3, 17 years ago
        Thanks for the reply coroico,

        Search is working, but the image is not being shown in the search results - just a link to the image gallery in which the image lives.

        I don’t have a chunk called subSearchGalleryPictureTpl (as below in the code) - is this a default template or a custom chunk?

        [+as.gal_idShow:is=`1`:then=`
          <br />[!MaxiGallery? &pic_query_ids=`[+as.gal_id+]` &galleryPictureTpl=`subSearchGalleryPictureTpl`!] 
        `+]<br />




          Tabor Carlton // Interactive Art Director
          http://www.taborcarlton.com
          http://www.alternative-media.net
          • 5811
          • 1,717 Posts
          Find below this chunk. I don’t remember but t think that this chunk is provided with maxigallery.
          [+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]" 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+]" height="[+maxigallery.picture_height_thumb+]" 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>
          `+]

            • 29163
            • 18 Posts
            tabor.carlton Reply #5, 17 years ago
            You’re right coroico,

            This chunk IS provided by maxiGallery - I cleared cache after trying both as &tpl but neither worked. I’m going to review the wiki again and see if I’m missing something, but everything but the image is showing up... got me puzzled.

            Thanks for your help, I’ll post back when and if I can uncover something.

              Tabor Carlton // Interactive Art Director
              http://www.taborcarlton.com
              http://www.alternative-media.net
              • 5811
              • 1,717 Posts

              Regarding the displaying of Maxigallery thumbnails, I have set up a new demo on the AS demo site. See: http://www.modx.wangba.fr/index.php?id=379

              And may be see this related post: http://modxcms.com/forums/index.php/topic,46257.msg272820.html#msg272820