We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 9446
    • 2 Posts
    Hello

    I have just started to use modx and i have just a single page on my website with a ID of 13. The problem is i cant find anywhere to reset the id back to 1. this is just a major inconvience as i dont want my pages to start from 13 onwards. is there anyway to reset the id back to 1 in the modx manager?

    much thanks

    Matthew
      • 33337
      • 3,975 Posts
      Thats not possible, and certainly not feasible. Since changing IDs will cripple all the links in the different db tables making the site unusable.

      There is one way, you will have to start fresh. smiley
        Zaigham R - MODX Professional | Skype | Email | Twitter

        Digging the interwebs for #MODX gems and bringing it to you. modx.link
        • 22303 MODX Staff
        • 10,725 Posts
        The best way to not have the pages start at ID 13 is not to delete any pages, but rather re-purpose them for new pages as they become obsolete. I generally keep a hidden/unpublished recycle container to shove obsolete pages in for this purpose.
          • 33337
          • 3,975 Posts
          Quote from: OpenGeek at Jun 12, 2009, 11:47 AM

          The best way to not have the pages start at ID 13 is not to delete any pages, but rather re-purpose them for new pages as they become obsolete. I generally keep a hidden/unpublished recycle container to shove obsolete pages in for this purpose.
          Nice tip Jason! smiley
            Zaigham R - MODX Professional | Skype | Email | Twitter

            Digging the interwebs for #MODX gems and bringing it to you. modx.link
            • 28042 ☆ A M B ☆
            • 24,524 Posts
            Another solution is to just not worry about it, the document ID has no real purpose except to organize and identify the documents in the database.

            If you don’t like the number 13, just duplicate it, then delete the #13. Then your documents will start with 14.
              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
              • 14779
              • 256 Posts
              I’ve been playing around with kiwee commerce, and it installs a bunch of chunks, snippets, TV’s, Templates, and documents. It starts the ID’s for all this stuff at 4000. I had 6 other documents setup, with ID’s 1-6, now after kiwee commerce is installed, all new documents have an ID of 4XXX. I’ll never have this many documents, so can I reset the ID’s so new documents have an ID that will follow the original documents?

                PM me to find out how you can get a FREE ipad 2!
                • 24935
                • 160 Posts
                TRY THIS AT YOUR OWN RISK

                Actually, I have done this before...
                1) Delete and purge all documents with a large id (if you want to keep them, but change the ids, that could mess up your site--I would only attempt that for simple pages that don’t have any keyword, tvs, or anything else connected to them--I think I have done that successfully before)

                2) Might want to clear the cache too.

                3) If you have phpMyAdmin, you can select the database, then select the table site_content, click on the Operations tab, chance auto_increment to 7 (or the next available number) and click go.

                Your ids should be reset for documents. You could follow a similar process for chunks and other elements too.
                  • 14779
                  • 256 Posts
                  great! thx!
                    PM me to find out how you can get a FREE ipad 2!