We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 11302
    • 7 Posts
    Is there a simple solution to link a parent resource directly to a child resource? I have several menu items that all have child menu items and making every parent resource a page would create a lot of extra clicking and unnecessary content.

    Here’s a similar post from 2005 that looks way outdated - http://modxcms.com/forums/index.php/topic,1394.0.html

    One solution would be to keep the parent resource empty and use 301 redirects to direct them to the desired resource, but that seems less than ideal.

    Thanks for your help.
      • 18373 ☆ A M B ☆
      • 3,141 Posts
      DropMenu is indeed outdated tongue

      The FirstChildRedirect snippet looks like what you need. It should be pre-installed in Evolution.

      If not: http://modxcms.com/extras/package/151?version=255


      If you’re looking for some more advanced redirect (somewhat): phiRedirect looks good: http://modxcms.com/extras/package/?package=338
        Mark Hamstra • Developer spending his days working on Premium Extras and a MODX Site Dashboard with the ability to remotely upgrade MODX and extras to make the MODX world a little better.

        Tweet me @mark_hamstra, check my infrequent blog at markhamstra.com, my slightly more frequent ramblings at MODX.today or see code at Github.
        • 26016
        • 561 Posts
        Yup, FirstChildRedirect. I think that snippet comes standard with MODx now. On the parent page, you just put
        [[FirstChildRedirect]] code there, if memory serves, and it will pass you along to the first item in that folder. You may need to rearrange menu item order in the folder to get it working the way you want it.

        I was told be an SEO guy that doing this is somewhat un-SEO-ish, so he actually kept landing pages for each parent. Not being an SEO expert, I really couldn’t say. In any case, I’ve used this snippet on a bunch of sites.

        Cheers
          MODx and Wordpress development
          Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4
          • 18373 ☆ A M B ☆
          • 3,141 Posts
          Quote from: samba at Jun 29, 2010, 12:37 PM

          I was told be an SEO guy that doing this is somewhat un-SEO-ish, so he actually kept landing pages for each parent. Not being an SEO expert, I really couldn’t say. In any case, I’ve used this snippet on a bunch of sites.

          Imo, if you have a category page sort of thing you could take advantage of it by making it show a list or something linking to the individual resources. It increases your internal links, and visitors might find it convenient to be able of looking into that specific category.

          I don’t think that making it redirect has a real negative influence on your SEO, but you are missing out on some potential advantages.
            Mark Hamstra • Developer spending his days working on Premium Extras and a MODX Site Dashboard with the ability to remotely upgrade MODX and extras to make the MODX world a little better.

            Tweet me @mark_hamstra, check my infrequent blog at markhamstra.com, my slightly more frequent ramblings at MODX.today or see code at Github.
            • 11302
            • 7 Posts
            Brilliant. Worked like a charm.

            And thanks for the SEO tip.