We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 8085
    • 4 Posts
    I am a total newbie to modX, so I started hacking away at a tiny snippet which uses methods I found here (http://wiki.modxcms.com/index.php/API:getAllChildren), like getActiveChildren. The reason this method is cool is that it sorts by the menu indexes by default.

    So I found out by looking here (http://api.modxcms.com/) that all of my methods are deprecated. I need to use getChildIds instead (which doesn’t sort by menu index), and then, how do I get info about the id? getPageInfo has been deprecated as well! getDocument has also been deprecated...

    So to recap, I need to getActiveChildren in a non-deprecated way, and get info about each page.

    [Frustrating that all the obvious stuff is deprecated but there’s no mention of where one SHOULD look... So any help would be greatly appeciated...]
      • 3749
      • 24,544 Posts
      First, are you using MODx Evolution or MODx Revolution?

      If you’re using Evo, many of those functions will remain useful in MODx 1.0, 1.1, 1.2, etc., even though they are deprecated for MODx 2.1+. It’s still a good idea to move away from them, but you can take your time doing it.

      If you’re using Revolution. This will help get you started on the alternatives: http://bobsguides.com/revolution-objects.html
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 8085
        • 4 Posts
        That’s perfect, thanks for that. I’m using Evolution but now I’m thinking that, if I can get my client to agree, I’ll try to use Revolution Beta.

        Turns out I can do everything my snippet was doing (though it worked!) with Wayfinder and using snippets as params, so I’m cool for now.
          • 3749
          • 24,544 Posts
          Glad to hear it. You’ll be much happier with Wayfinder. wink

          The Revolution Beta is fairly stable and solid. I should mention that Wayfinder isn’t working in Revo at the moment, although the fix is committed and should be available very soon (maybe by the time you read this).
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting
            • 17499 ☆ A M B ☆
            • 872 Posts
            Quote from: BobRay at Aug 22, 2009, 01:30 PM

            I should mention that Wayfinder isn’t working in Revo at the moment, although the fix is committed and should be available very soon (maybe by the time you read this).

            It’s not working if you use the last svn, otherwise, it works with last public bêta isn’t it?
              • 22303 MODX Staff
              • 10,725 Posts
              Quote from: lossendae at Aug 22, 2009, 01:37 PM

              Quote from: BobRay at Aug 22, 2009, 01:30 PM

              I should mention that Wayfinder isn’t working in Revo at the moment, although the fix is committed and should be available very soon (maybe by the time you read this).

              It’s not working if you use the last svn, otherwise, it works with last public bêta isn’t it?
              Correct, specifically it’s a problem with the latest development branch (branches/2.0/ vs. latest "stable" branch at branches/revolution/).