We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 7455
    • 2,204 Posts
    Snippet: ListRelated

    Version: 0.9.2
    Date: 2006.04.07
    Originaly made by: [email protected]
    ModXifed by [email protected]
    added the option to set the in menu option
    This snippet was designed to show a list of pages that are related based on specified keywords, or those used in the current page

    I use this snippet to get a list of projects made for the same client.

    Thanks to Jared for the original code

    Greets Dimmy
      follow me on twitter: @dimmy01
      • 4273
      • 356 Posts
      got it working, cool snippet,

      how come this code was not in the updated version ? I tried using it but it didn’t display a message, is there another way to do it ?
      // $nonefound [ ’string’ ]
      // What to return when no related records are found.
      $nonefound = ’<p>No related pages or links.</p>’;
        SMF Bookmark Mod - check it out
        http://mods.simplemachines.org/index.php?mod=350
        • 7455
        • 2,204 Posts
        The way I wanted it was that it did not show any thing when there was none. so it works as designed.
        But you are free to tinker with it to get this to work.
          follow me on twitter: @dimmy01
          • 4273
          • 356 Posts
          ListRelated doesn’t appear to include weblinks is there a way to do this ?

          it will list all other docs but not weblink
            SMF Bookmark Mod - check it out
            http://mods.simplemachines.org/index.php?mod=350
            • 7455
            • 2,204 Posts
            Quote from: bugsmi0 at May 27, 2006, 03:32 PM

            ListRelated doesn’t appear to include weblinks is there a way to do this ?

            it will list all other docs but not weblink

            maybe that because weblinks can not have keywords/metatags? this snippet uses that to determan which document are related.
              follow me on twitter: @dimmy01
              • 22815
              • 1,097 Posts
              How does this differ from the version of ListRelated "1.0 beta 1, September 6, 2005" that Ryan did that is in the standard install of MODx 0.9.2.1?

              It seems Ryan and Dimmy both started with the same etomite code.

              I note Dimmy says "added the option to set the in menu option", and Ryan’s version says "Needs to be updated to support Webuser Logins Menu Items and also possibly "in menu" items."

              That would suggest that Dimmy’s version is "better".
              I haven’t actually had a need for this code yet so I can’t really test it. Would people recommend replacing Ryan’s "1.0 beta 1" with Dimmy’s "0.9.2"?
                No, I don&#39;t know what OpenGeek&#39;s saying half the time either.
                MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
                Forum: Where to post threads about add-ons | Forum Rules
                Like MODx? donate (and/or share your resources)
                Like me? See my Amazon wishlist
                MODx "Most Promising CMS" - so appropriate!
                • 22303 MODX Staff
                • 10,725 Posts
                Quote from: PaulGregory at May 30, 2006, 05:57 PM

                How does this differ from the version of ListRelated "1.0 beta 1, September 6, 2005" that Ryan did that is in the standard install of MODx 0.9.2.1?

                It seems Ryan and Dimmy both started with the same etomite code.

                I note Dimmy says "added the option to set the in menu option", and Ryan’s version says "Needs to be updated to support Webuser Logins Menu Items and also possibly "in menu" items."

                That would suggest that Dimmy’s version is "better".
                I haven’t actually had a need for this code yet so I can’t really test it. Would people recommend replacing Ryan’s "1.0 beta 1" with Dimmy’s "0.9.2"?

                Yes; most of the snippets in 0.9.2.x are not updated, because the release was a security release. We are working on a dedicated repository for add-ons, along with processes to help manage the multitude of add-ons and various versions of add-ons people have hacked for their own purposes, to make up for deficiencies in various MODx releases, etc., and then contributed back to the project. It’s definitely a bit of a mess at the moment.

                Also, I recommend NOT to replace the core snippets, so you can easily upgrade them to the latest when the next release arrives that does contain the latest versions. It’s always better to duplicate and rename to something unique that will not get overwritten if you do choose to upgrade.
                  • 22815
                  • 1,097 Posts
                  My point was that there seemed to be two completely different MODx-isations of etomite code and I wasn’t sure which code to use, regardless of what I called the snippet. It looks like they are both called ListRelated because that’s what Jared’s etomite snippet was called. But Dimmy’s ListRelated 0.92 (I assume the numbering is coincidence) looks better than Ryan’s 1.0 Beta.

                  I wish you well with the repository. It looks like a pretty complicated task to get this fork mess together looking at what has happened in the absense of organised version numbers, and a system would be a great help.

                  Anyway. Is anyone out there using Dimmy’s version of ListRelated in preference to Ryan’s? Or are people using entirely different snippets for this function?
                    No, I don&#39;t know what OpenGeek&#39;s saying half the time either.
                    MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
                    Forum: Where to post threads about add-ons | Forum Rules
                    Like MODx? donate (and/or share your resources)
                    Like me? See my Amazon wishlist
                    MODx "Most Promising CMS" - so appropriate!
                    • 25663 MODX Staff
                    • 12,272 Posts
                    Quite simply the right answer is to use what works for you!
                      Ryan Thrash, MODX Co-Founder
                      Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                      • 22815
                      • 1,097 Posts
                      Yes, but knowing what works for others, and indeed which version would be selected to be included with 0.9.5 is clearly beneficial. Is this or is this not a core snippet?
                        No, I don&#39;t know what OpenGeek&#39;s saying half the time either.
                        MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
                        Forum: Where to post threads about add-ons | Forum Rules
                        Like MODx? donate (and/or share your resources)
                        Like me? See my Amazon wishlist
                        MODx "Most Promising CMS" - so appropriate!