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

    I have a server running modx, locally (e.g: in the same LAN) modx pages are working fine; outside the LAN (I have an ISP natting outside address to my local address), modx site return generally a blank page.

    The first page of my modx is a simple WebLogin, which is working fine from inside and outside.
    After loggin, I can use modx only in my local LAN. All others pages return a blank page from the outside.

    I removed all files in my cache folder, then I got following error:
    « 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: 	/******/modx/manager/includes/document.parser.class.inc.php	 
      Line: 	1211	 
      Line 1211 source: 	foreach ($this->documentMap as $mapEntry) { 	 
     
    Parser timing
      MySQL: 	0.0014 s	(5 Requests)
      PHP: 	0.0270 s	 
      Total: 	0.0284 s
    


    On the page where I should be redirected after loggin, there is only a simple menu (WayFinder).
    Modx manager is working inside and outside my LAN.

    This problem started when I change my DNS provider for the outside IP address.
    I do not see how it is linked, there aren’t any reference to the DNS name on apache conf or other..

    Does anyone have a tip to get this working ?
    Hope I was clear enough tongue

    Server:
    Ubuntu 8.04
    Apache 2
    MySQL 5
    PHP 5
    MODx 0.9.6.2
      • 26903
      • 1,336 Posts
      I’ve seen something similar to this on my setup, I have a machine on a lan behind a firewall/router, on the lan it has a 192.168.... address, outside it has an internet routable IP address, normal stuff really. Sometimes when I’ve accessed the site from the outside the front page has no css styling, on looking at the source of the page it is looking for the css files on the local lan, not the outside address, because I used the local address to view the site locally, then went ’outside’ as it were.

      To clear it go to the manger page from the outside, log-in and clear the cache, its OK then.

      When you say you have removed your cache files do you mean you have physically deleted them? If so this will break the site I think and may be the error you are now seeing.
        Use MODx, or the cat gets it!
        • 24627
        • 3 Posts
        Hi,

        I cleared the cache manually (physically), as you said it is not be the better way.
        To be sure I have a clean install, I backup the DB, deleted all, reinstall modx and restored the DB (and my snippets).

        But it is still the same issue, and is it not intermittent, I always have the same behaviour sad
        Now, I only have a blank page, no error.

        Thanks for your reply.

        If someone have any idea on what happened ?
        In the mean time, may be I can try to redo all my pages to see if there is something inside undecided


          • 26903
          • 1,336 Posts
          OK, start with your apache logs, do you have any errors? What does the access log say when it works from the inside and when it doesn’t from the outside. Also, has this ever worked since you changed your DNS provider or not?
            Use MODx, or the cat gets it!
            • 3749
            • 24,544 Posts
            Try doing an upgrade install of MODx (reupload the install folder if it’s not there). Uncheck all the boxes for installing add-ons and the sample website. That will restore the necessary files in the cache foder.

            In the future, clear the cache using the Manager Clear Cache command.

              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
              • 24627
              • 3 Posts
              HI,

              Thanks for your hints.
              I did not have any log on apache, all was really silent (it was frustrating). And yes it worked fine before DNS provider change.

              I preferred to redo from scratch my modx, since I do not have much pages and snippets, it was not too hard to manage (long but not hard :p).
              Since then, it is working fine inside and outside.
              The pages and snippets are the same, so I do not know what happened.

              Anyway, all is working fine.

              Thanks again to all who replied, and thanks to modx coders smiley