We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 27725
    • 9 Posts
    Hello,
    is it possible, with AjaxSearch 1.8 (or previous releases), to find documents with ditto included content?

    Example:
    Document 1 with a picture and a TV "picture-description".
    A Ditto-Call includes the picture and the TV "picture-description" of Document 1 on Page 1.

    AjaxSearch finds the searchword only in Document 1, but not in Page 1.
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Well, not really, since that page does not exist until the page is generated and the Ditto call processed.

      That’s a problem with dynamically generated content; until the content is generated, it doesn’t exist and cannot be searched internally.

      You might need some outside search like Google Search, which actually requests the pages then searches what it gets in the way of finished pages.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 27725
        • 9 Posts
        Thank You for the answer,
        but why can´t AjaxSearch follow or process the ditto call?
        In my opinion a SearchEngine in a CMS should not only search in specific database fields, but in the rendered page too, or a special sort of cache or something like that.
          • 7231
          • 4,205 Posts
          but why can´t AjaxSearch follow or process the ditto call?
          All the pages would need to be parsed, and all snippets, for each search, which you could imagine would be resource intensive. Not all pages are cached and some snippets generate dynamic data which is not cached, so searching the cache will not work. Most CMS use database table search, I am pretty sure that the native WordPress search do.

          Is your problem that you have a document witch gets it’s data from other documents and you want the data to be included in the search results but you don’t want anyone going to the ’hidden’ documents? If this is the case you can add a redirect command which will take the visitor to the compiled Ditto based document. This way the data is included in the search but the individual document is not accessible.
            [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

            Something is happening here, but you don't know what it is.
            Do you, Mr. Jones? - [bob dylan]
            • 27725
            • 9 Posts
            On the side appear different pictures. These pictures are independent documents with a picture signature, a special headline and more. Onclick these pictures will open in a new window. To find the single picture documents is not wrong, however, more nicely it would be if, in addition, the side with the ditto included pictures, headlines and picture signatures would be found too.