We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17613
    • 11 Posts
    Hi everybody!

    I have a problem with my first MODx site. When I view the page without www in front of the URL, the page is fine, but if I put www in front there’s just a blank page and nothing else. Could somebody give a hint at what could cause this and how to fix it?

    Additional info, the nameservers seem to be configured correctly because I can access individual files on the server with or without the www just fine. So it indeed is a MODx issue.

    I am using the latest version 0.9.6.1

    Thanks guys
      • 25663 MODX Staff
      • 12,272 Posts
      That sounds like a DNS or Apache configuration issue. Do you have a ".htaccess" file in your MODx root installation location?
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 17613
        • 11 Posts
        Hi,

        yes I did have the .htaccess file in the root folder. But I tried without it early on because I thought the problem might be because of it and the friendly URLs. So I turned them off but the same problem’s still there - blank page when I access the site with www in front.

        How could this be a DNS issue when I can access individual files just fine with the www in front..?

        Oh, I also tried using the default template, but it’s the same. And also without the base url in the html.

        Any suggestions..? huh
          • 25663 MODX Staff
          • 12,272 Posts
          If you turn off friendly URLs you also need to change .htaccess back into ht.access (or otherwise rename it). What is the website in question? I’ll pull a DNS report to see if your zone file looks right; it sounds like you don’t have an A record for your-URL.com but you do for www.your-URL.com. Then again, I’m probably completely wrong. tongue
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
            • 17613
            • 11 Posts
            Quote from: rthrash at Nov 25, 2007, 08:12 AM

            If you turn off friendly URLs you also need to change .htaccess back into ht.access (or otherwise rename it). What is the website in question? I’ll pull a DNS report to see if your zone file looks right; it sounds like you don’t have an A record for your-URL.com but you do for www.your-URL.com. Then again, I’m probably completely wrong. tongue

            Hi,

            there are "IN / A" DNS records for both domainname.com and *.domainname.com, pointing to the same IP. I’d rather not give the site’s URL in public, but if you need to make the report and verify I can send you a private message. But yes, the A records are there for both. Oh and yeah I renamed the .htaccess when I disabled friendly URLs. smiley

            One thing I noticed when I checked the site again... it was a blank page even without www in the URL - until I logged in to the manager. So... do I have to enable anonymous access somewhere..? I didn’t find anything in the settings. I didn’t install the example site but did a blank install, so maybe I’m missing something in the settings..?

            One thing I was also thinking about is whether the installer script asked for the site URL, and whether or not I put a www in front of the URL there... I might have to do a complete re-install to find out if that makes the difference...
              • 25663 MODX Staff
              • 12,272 Posts
              It now sounds like there may be some corrupt files from your original FTP upload based on the new info. You might try re-uploading the files to see if that makes a difference or I’m sure someone else will chime in with another suggestion. Similar things have surfaced from time to time.
                Ryan Thrash, MODX Co-Founder
                Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                • 22303 MODX Staff
                • 10,725 Posts
                If the page is blank only when not logged into the manager, that means that your content is a) not published or b) has been secured from viewing by anonymous users. This would explain the www discrepancy, as the user session for the domain.com and www.domain.com would be different.
                  • 17613
                  • 11 Posts
                  Hi,

                  so today I did it - everything from the beginning. On a different computer.

                  - downloaded the ModX zip file (previously I had used the tar.gz so thought that might help also)
                  - unzipped the files and transferred them to the server.
                  - changed the file permissions as listed here: http://modxcms.com/installation-and-configuration.html
                  - used the installer to install a fresh installment.
                  - accessed the manager by clicking Close at the end of the installation
                  - Made some basic changes in Tools->Configuration - I think I only changed the site name...
                  - Checked out the site, looked ok (the default page). It worked with and without www in the url, even with a different browser that didn’t have the manager session on.
                  - Went to edit the default document; changed title, alias, text...
                  - Did something in the manager, at least cleared cache
                  -> this resulted in a Blank page, with or without the www in URL, or a modx manager session.
                  - Still when I select "Preview Document" from the site tree, the page displays ok.
                  - checked from Edit document page that "All Document Groups (Public)" is checked in access permissions
                  - Chose "Publish page" from the site tree just to make sure.

                  Actually the blank page is blank in Firefox, but in IE it says the "Page cannot be displayed" thing.

                  It does seem like a rights problem since the Preview page works when it opens it without www in the URL.
                  But why is that? My page overview seems like it’s published and publicly accessible.

                  So what do you suggest now..?

                  This is the document overview for the home page:

                  General
                  Title: Home
                  Long title: home
                  Description: home
                  Summary (introtext): (Not set)
                  Type: Document
                  Document’s alias: home
                  Keywords: (Not set)
                  META tags: (Not set)

                  Changes
                  Created: 26/10/05 00:32:01 (admin)
                  Edited: 27/11/07 16:40:15 (admin)

                  Status
                  Status: Published
                  Publish date: (Not set)
                  Un-publish date: (Not set)
                  Cacheable: Yes
                  Searchable: Yes
                  Menu index: 0
                  Show in menu: Yes
                  Web access: Public
                  Manager access: Public

                  Markup/structure
                  Uses template: Minimal Template
                  Edit using rich text editor: Yes
                  Document is container: No
                    • 25663 MODX Staff
                    • 12,272 Posts
                    Still on the same server (or using the same PHP/MySQL/Apache config)? If so, I’d try a different server or try XAMPP locally.
                      Ryan Thrash, MODX Co-Founder
                      Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                      • 17613
                      • 11 Posts
                      Quote from: rthrash at Nov 27, 2007, 07:09 PM

                      Still on the same server (or using the same PHP/MySQL/Apache config)? If so, I’d try a different server or try XAMPP locally.

                      Yep, on the same server. What server config could cause this anyway? It’s hard to change the server, and it would be better for MODx development as well to find out what the problem is; the host is ixwebhosting.com which is a fairly popular host.

                      In the cache folder the cache files are created by MODx with 644 rights. The installation manual said to change cache folder+files to be fully writable (which I did), but should that also be the case for the files created by MODx itself..? I couldn’t change the rights to test since the web server owns the files...

                      I might try later today to disable caching altogether on the site and see if that helps... Or can I config the rights from MODx - I saw I can for documents, but how about the cache files? If that could even cause the problem since there are read rights for the files anyway... but maybe execute rights are required or something.