We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44922
    • 131 Posts
    Thanks for pointing out the location. tree_default_sort and menuindex is indeed the setting here. You're right, using publishedon would be a bit of a pain - especially as Articles has worked well in the past. Strange that there appear to only be a handful of others on the forum reporting similar issues.

    For now, I've just "removed from menus" so this no longer displays in the main nav and have used GetResources to take the user into the news Articles section from the home page. "Remove from menus" solves the issue as a temporary fix.
      • 49486
      • 2 Posts
      I've had the exact same issue just yesterday. I'm using Revolution 2.3.1.

      On a new site that I'm creating I had a single document resource ('Home': ID 1) and then added an Articles resource ('Blog', ID 2), to which I added a couple of articles (IDs 3 and 4). Later I added three new document resources ('About Us': ID 5, 'Services': ID 6 and 'Careers': ID 7) and as I wanted the blog to appear last on the live site menu I changed the menuindex for it to be 8. At that point, the services and careers resources disappeared from the resource tree in the manager. I could still edit the resources by manipulating the edit URL for a resource that hadn't disappeared.

      To try and get round this I tried deleting and readding the two resources but to no avail - they still wouldn't appear. I also tried toggling both the publish and hide from menu options for the resources, and setting the menuindex for the blog to an even higher value (20) but they still failed to appear.

      Following Bob's advice earlier in this thread I examined modx_site_content
      select id, parent, menuindex, pagetitle from modx_site_content;

      to check the parentage of the missing resources and they correctly had 0 as their parent resource.

      By now I had resource IDs up to 10 due to deleting (also using 'Remove deleted resources' to purge the deleted resources) and readding, so I decided to try changing the IDs of the resources directly in the database.

      I changed the IDs for resources 9 and 10 (the recreated services and careers resources) to be 3 and 4 (the IDs I had for those resources before I deleted them) and then changed the ID for the blog from 2 to 10. I then flushed the cache and refreshed the resource tree in the manager and hey presto, all of the resources now appear.
        • 3749
        • 24,544 Posts
        Be aware that changing Resource IDs in the database will leave orphaned intersect objects for TVs (modTemplateVarResource), Templates (modTemplateVarTemplate), and Resource Groups (modResourceGroupResource) that will never be deleted. You can remove them by hand, but it's pretty tedious. This is another option, but it's not free: SiteCheck. [ed. note: BobRay last edited this post 11 years, 9 months ago.]
          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
          • 49486
          • 2 Posts
          Quote from: BobRay at Dec 06, 2014, 09:56 AM
          Quote from: BobRay at Dec 06, 2014, 09:55 AM
          Be aware that changing Resource IDs in the database will leave orphaned intersect objects for TVs (modTemplateVarResource), Templates (modTemplateVarTemplate), and Resource Groups (modResourceGroupResource) that will never be deleted. You can remove them by hand, but it's pretty tedious. This is another option, but it's not free: SiteCheck.

          Thanks for the caution Bob - in my case as the site is still pretty much a shell I got away with it, but it's something to be borne it mind! Would be interesting to understand why the resource tree loses the resources - presumably it's a defect to do with the way that Articles hides its children but that's pure guessing!