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

    Hopefully subject says it all.

    I’m having problem with WAMP localhost setup I need localhost/modx_parthian/ to be resolved to /index.php.

    WinXP, Evolution 1.0.0 with Sample Project.

    I have re-installed. Renamed the two ht.access and in the root .htaccess modified
    RewriteBase /modx_parthian

    I installed the sample project and all its links do not have index.php so my site navigation doesn’t work (without me adding index.php manually). So if I use URL http://localhost/modx_parthian/manager/ I just see the Index of the folder.

    I have also turned FriendlyURLs on (and off again - all sorts of combinations) and my httpd.conf has the mod_rewrite on. I must have been through this same pain a few months ago as I have a note to look at http://svn.modxcms.com/docs/display/MODx096/Friendly+URL+Solutions

    Any ideas?

    Stuart
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Sounds like you need to add index.php as the server’s index page; it probably is configured to use index.html. You can have both, just put index.php before index.html in the configuration.

      http://httpd.apache.org/docs/1.3/mod/mod_dir.html#directoryindex
        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
        • 22704
        • 42 Posts
        Wonderful.

        # DirectoryIndex: sets the file that Apache will serve if a directory
        # is requested.
        # For MODx - add index.php to the start
        <IfModule dir_module>
        DirectoryIndex index.php index.html index.html.var index.php5
        </IfModule>

        Should this process be documented more clearly? Perhaps it is but I had a good look around and found little. It seems a shame to have to have a Degree in Computer Science or a lot of experience to be able to figure out how to get the Sample site working under a local WAMP. My guess is that everyone who tries what I have done (can’t be uncommon) must likely hit the same problem.

        Perhaps a line on http://svn.modxcms.com/docs/display/MODx096/Friendly+URL+Solutions

        Cheers
          • 33337
          • 3,975 Posts
          Usually this doesn’t happen because default MODx install doesn’t come with index.html in its root directory. smiley
            Zaigham R - MODX Professional | Skype | Email | Twitter

            Digging the interwebs for #MODX gems and bringing it to you. modx.link
            • 18367
            • 834 Posts
            Parthian

            had a good look around and found little.

            Actually there’s a huge, never ending thread on getting friendly urls to work. Surprised you didn’t find it.

            I’ve often thought it would be good for someone to go through that thread and itemise and document all the issues people have with friendly urls, .htaccess, but then we’re all volunteers here and it all takes time.

            It’s best just to ask the question, I’ve found you get answers really quickly.

            grin
              Content Creator and Copywriter
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              If one is going to be running a web server, even if it is just a local development server, it would be logical to learn a bit about how web servers work. This is a forum for using MODx, not basic system administration.

              Like some people I once worked as a housekeeper for; they had a fancy convection/microwave oven, and in spite of the HUGE RED WARNING LABELS on both the unit and its manual they had installed it in an enclosed cupboard. Then they blamed me when it overheated and stopped working about six months after I pointed out the fact that it was designed to be out on an open countertop.
                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
                • 3749
                • 24,544 Posts
                Quote from: parthian at Aug 14, 2009, 01:38 PM

                Wonderful.

                DirectoryIndex index.php index.html index.html.var index.php5

                Should this process be documented more clearly? Perhaps it is but I had a good look around and found little. It seems a shame to have to have a Degree in Computer Science or a lot of experience to be able to figure out how to get the Sample site working under a local WAMP. My guess is that everyone who tries what I have done (can’t be uncommon) must likely hit the same problem.

                It just made the Installation FAQ at my site: http://bobsguides.com/modx-installation-faq.html smiley

                BTW, I’m not sure there’s any point to the conditional since, if the statement doesn’t execute, your site won’t work. Maybe I’m missing something.
                Also, unless you have a specific reason for having the other alternatives, this would be slightly more secure and it’s all MODx would need:

                DirectoryIndex index.php 
                  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