We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 32543
    • 7 Posts
    I have a fresh install of MODx Evolution 1.0.0 on a LAMP set-up. Installation went without a hitch.

    I added 3 sample pages using the default template. I have not customized the default install at all at this point.

    When I go into TOOLS > EXPORT STATIC HTML and try and run it, I get the following error:

    Found 4 Resources to export...
    Exporting file 1 of 4
          MODx CMS Install Success, id 1
          
    Failed! Cannot retrieve document.
    Exporting file 2 of 4
          Page Two, id 2
          
    Failed! Cannot retrieve document.
    Exporting file 3 of 4
          Page Two Sub, id 4
          
    Failed! Cannot retrieve document.
    Exporting file 4 of 4
          Page Three, id 3
          
    Failed! Cannot retrieve document.
    Export finished. Export took 0.01 seconds to complete.
    


    I’ve checked to be sure that my "assets/export" directory is writable and it is.

    This site is installed and working properly in a subdirectory of the root. I’m wondering if this is contributing to the issue.

    I can’t find anything on the forums that has this same error. The other threads don’t help with my issue. I also have an install on a WAMP server and have the exact same issue.

    Any ideas?
      • 22303 MODX Staff
      • 10,725 Posts
      Check your phpinfo for allow_url_fopen setting. This must be enabled for the static HTML export to function.
        • 32543
        • 7 Posts
        It is "ON" for both of my servers (php on windows and the other on Linux).
          • 22303 MODX Staff
          • 10,725 Posts
          Are the pages actually published and accessible when you are not logged in to the manager?
            • 32543
            • 7 Posts
            Yes, they are.
              • 22303 MODX Staff
              • 10,725 Posts
              I can’t find any reason for this; can you provide details of your environments so we can research this further? Also, check your Apache error_log to see if any PHP errors are being reported there.
                • 32543
                • 7 Posts
                PHP Version 5.2.9
                MySQL - 5.0.79
                Plesk 8.6

                Here’s the error that it’s generating in the Apache log for each page it calls right after I click Export Static HTML:
                [Sun Sep 27 08:32:59 2009] [error] [client 127.0.0.1] File does not exist: /var/www/html/content

                So in seeing the error it’s pretty clear to me that it is looking in the wrong place. It’s looking in the default virtual directory which is not where this site is located.

                The main site is hosted in /var/www/vhost/mydomainname.com/httpdocs/content, which is automatically created by Plesk. The MODx implementation is working fine.

                Looks like I might be missing a configuration setting or something? Is there somewhere I can override the directory that the Export function is looking to as the base for it’s calls?


                  • 22303 MODX Staff
                  • 10,725 Posts
                  Are you by chance exporting any documents that do not have an alias assigned? Are you using friendly_urls?
                    • 32543
                    • 7 Posts
                    All aliases are defined and I am using friendly URLs (enabled in config page) in this implementation.
                      • 22303 MODX Staff
                      • 10,725 Posts
                      Quote from: Witspigot at Sep 27, 2009, 09:27 PM

                      All aliases are defined and I am using friendly URLs (enabled in config page) in this implementation.
                      From the error messages you reported, it’s using MODX_SITE_URL to determine the path. Unless this is wrong in your site when you view it, I don’t see any reason for the PHP errors you are seeing. If you can’t get it to work, I’d report this as a bug in Jira and a developer will have to work with you to see what the problem might be. Nothing obvious from reviewing the code...