We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 27108
    • 13 Posts
    OK, I am going to follow your advice. I have restored my database with phpmyadmin, which didn’t seem to do much, but I have found that by renaming the assets folder I get some of my site back--I can login to manager again at least, and the error when I try to visit my site is a modx error caused by the missing assets folder, rather than the ’fatal error’ I had before. I don’t know if restoring the database helped--I think it was renaming the assets folder that did it.

    So, the problem is in the assets folder? And this is somehow screwing up my ability to ftp? That makes no sense to me or to the seemingly experienced tech guy I spoke to at my host...If I can upload again, should I re-upload the install directory, and run that to re-create the assets folder, and then add the snippets etc bit by bit from my backup?

    Thanks,
    Stephen.
      • 27108
      • 13 Posts
      Okay, now I am back to my original error. I can get in to the manager. But pages still show this error. It’s got to be something simple, no?

      Quote
      « MODx Parse Error »
      MODx encountered the following error while attempting to parse the requested resource:
      « PHP Parse Error »

      PHP error debug
      Error: Invalid argument supplied for foreach()
      Error type/ Nr.: Warning - 2
      File: /home/httpd/vhosts/cupe3908.org/httpdocs/manager/includes/document.parser.class.inc.php
      Line: 1210
      Line 1210 source: foreach ($this->documentMap as $mapEntry) {

      Parser timing
      MySQL: 0.0199 s (11 Requests)
      PHP: 0.1142 s
      Total: 0.1341 s
        • 27108
        • 13 Posts
        Think I have resolved this by following the advice given here! I don’t know if I am supposed to tag this resolved in some way?

        I backed up the database, then erased it, created a new one, deleted the original assets and manager directories and did a fresh install with Evolution 1.0 or whatever is the recent version, and restored the database.

        Now all is looking basically good. I think I need to reimport my chunks, TVs etc. I will do them one at a time and test with each in case something here caused the original problem.

        Massive thanks to BobRay and JusiCGN!!!

        Stephen.
          • 3749
          • 24,544 Posts
          That’s great. I’m glad you didn’t lose your content. smiley

          Your idea of adding the chunks back one-by-one is a good one.

          Did you run an upgrade install? That has solved the "invalid argument" to foreach for other people.

          When things are settled, just reply and add [SOLVED] to the subject line.
            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
            • 27108
            • 13 Posts
            I ran a fresh install. I tried the upgrade but still had the same problem.

            I got an error when I tried to view the chunks due to the different name of the new tinymce (newer version in 1.0), so I uploaded the old version as well. Then I opened all the chunks and resaved them.

            AND IT ALL WORKS!!! Now I can relax and get some sleep...Except that getting this sorted out has given me a rush, and now I’m eager to tweak one or two more things on my site. Thanks again,

            Stephen.
              • 21054
              • 78 Posts
              I had the same problem today and managed to resolve it by clearing the cache: http://modxcms.com/forums/index.php/topic,42116.0.html