We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 5763
    • 59 Posts
    I have problems with friendly URLs. When i rename ht.access to .htaccess i receive an 500 error. Modx is installed in public_html tongue. Any ideas ? I have mod rewrite because it worked with other cms-s
      Be Smart, Think Free, Choose OpenSource
      • 7923
      • 4,213 Posts
      Comment out all other lines in .htaccess but RewriteEngine, RewriteCond and RewriteRule lines.. I.E. put # before the php_flag, php_value... etc. lines. Also if your MODx install is in a subdirectory, you have to put RewriteBase to point to that directory, like: RewriteBase /modx


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 5763
        • 59 Posts
        Thanks for the response doze it worked. The install isn’t in a subdirectory. Maybe this comment should be added to the .htaccess so other people can read it smiley.
          Be Smart, Think Free, Choose OpenSource
          • 21579
          • 10 Posts
          I can’t get this search engine friendly url feature to work. I think I’ve tried everything to no avail. I’m running modx on a windows2003 embarrassed test server using apache2.? with mysql and php5 installed. I’ve spent the better part of today trying to get it to work and about about to pull my hair out! smiley Any suggestions would be greatly appreciated
            • 32241
            • 1,495 Posts
            Have you tried using mod rewrite in other application using the same server and it works?

            Try this code, put it on a new .htaccess
            # It will prevent directory listing or file access using http
            Order deny,allow
            Deny from all
            
            #File types for which we make an exception.
            <Files ~ "\.(gif|jpg|jpeg|png)$">
                Order allow,deny
                Allow from all
            </Files>
            


            Put the file on a new folder on your root dir. Add test.txt file and test.jpg file in that folder.

            Try accessing both files using your web browser. If your server support htaccess, it should allow the jpg file to be accessed, but not the txt file.
            Report back to us.

            Anyway, there might be a better way to check this kind of thing, but I have no experience in it. So hopefully this will help out.
              Wendy Novianto
              [font=Verdana]PT DJAMOER Technology Media
              [font=Verdana]Xituz Media
              • 21579
              • 10 Posts
              So it looks like the mod_rewrite is not loaded properly. I have no knowledge of apache really so if you could explain how to load this module that might solve this issue. All I did was un-comment the loadModule line and restart apache grin


                • 21579
                • 10 Posts
                Here’s an image of the httpd.config:


                  • 8471
                  • 333 Posts
                  Quote from: Djamoer at Mar 23, 2006, 03:27 AM

                  Have you tried using mod rewrite in other application using the same server and it works?

                  Try this code, put it on a new .htaccess
                  # It will prevent directory listing or file access using http
                  Order deny,allow
                  Deny from all
                  
                  #File types for which we make an exception.
                  <Files ~ "\.(gif|jpg|jpeg|png)$">
                      Order allow,deny
                      Allow from all
                  </Files>
                  


                  Put the file on a new folder on your root dir. Add test.txt file and test.jpg file in that folder.

                  Try accessing both files using your web browser. If your server support htaccess, it should allow the jpg file to be accessed, but not the txt file.
                  Report back to us.

                  Anyway, there might be a better way to check this kind of thing, but I have no experience in it. So hopefully this will help out.

                  Hi, I have tried this and It works, but I still receive a 500 error and I can’t find a solution...
                    Sorry for my bad English grin